Skip to content

Instantly share code, notes, and snippets.

View jugatsu's full-sized avatar

Anton Kvashenkin jugatsu

View GitHub Profile
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- argocd-ns.yaml
# https://github.com/kubernetes-sigs/kustomize/issues/3815
namespace: argocd
helmCharts:
[NH_COMMON]
NH_TCPIP=Enabled
[NH_TCPIP]
NH_SERVER_ADDR=192.168.43.10
NH_PORT_NUMBER=475
NH_TCPIP_METHOD=UDP
NH_USE_BROADCAST=Disabled
variable "c2_access_key" {}
variable "c2_secret_key" {}
provider "aws" {
access_key = "${var.c2_access_key}"
secret_key = "${var.c2_secret_key}"
region = "us-east-1"
endpoints {
ec2 = "https://api.cloud.croc.ru:443/"
@jugatsu
jugatsu / main.tf
Created February 1, 2019 18:46
terraform Yandex.Cloud snippet
provider "yandex" {
token = ""
cloud_id = ""
folder_id = ""
zone = "ru-central1-a"
}
data "yandex_compute_image" "win" {
family = "windows-2012r2-gvlk"
}
new-module -name Omnitruck -scriptblock {
[Console]::OutputEncoding = New-Object -typename System.Text.ASCIIEncoding
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]'Tls,Tls11,Tls12'
function Get-PlatformVersion {
switch -regex ((Get-Win32OS).version) {
'10\.0\.\d+' {$platform_version = '2016'}
'6\.3\.\d+' {$platform_version = '2012r2'}
'6\.2\.\d+' {$platform_version = '2012'}
'6\.1\.\d+' {$platform_version = '2008r2'}
resource "openstack_compute_instance_v2" "basic" {
name = "basic"
flavor_name = "general.nano.dme.linux"
image_id = "8327cbb4-c573-464d-b5c0-c8c33409c7b2"
key_pair = "ak-pc"
user_data = ""
network {
name = "default-network"
}
@jugatsu
jugatsu / ansible-mikrotik-example.yml
Created January 10, 2018 14:13
ansible-mikrotik-example
---
# tasks file for ansible-role-mikrotik-ipsec
- name: Check RouterOS version.
raw: ":local varif [/system package update get installed-version]; :put \"$varif\""
args: { executable: False }
register: installed_version
changed_when: False
- name: Set custom fact for RouterOS version.
image: docker:latest
variables:
CONTAINER_TEST_IMAGE: $CI_REGISTRY/$CI_PROJECT_NAMESPACE/ui_test:latest
CONTAINER_IMAGE_PATH: $CI_REGISTRY/$CI_PROJECT_NAMESPACE/$CI_PROJECT_NAME
DOCKER_DRIVER: overlay2
PRODUCTION: jugatsu.xyz
STACK_PROD: deploy/production/stack-ui.yml
STACK_REVIEW: deploy/review/stack.yml
STACK_PROD_NAME: prod
MANAGER_IP: 104.199.29.228
@jugatsu
jugatsu / gitlab-ci.yml
Created December 17, 2017 19:10
gitlab-reddit-deploy-ci
image: alpine:latest
stages:
- test
- staging
- production
test:
stage: test
script:
@jugatsu
jugatsu / gitlab-ci.yml
Created December 17, 2017 19:08
gitlab-post-ci
image: alpine:latest
stages:
- build
- test
- review
- release
- deploy
- cleanup