Skip to content

Instantly share code, notes, and snippets.

View git001's full-sized avatar

Aleks git001

View GitHub Profile
@git001
git001 / upstream-proxy.md
Created June 19, 2024 18:29
Upstream-proxy Sequence diagram

Sequence diagram

sequenceDiagram

  participant CL AS Client
  participant HA AS HAProxy
  participant UP AS Upstream Proxy
  participant DS AS Destination Server
[SERVICE]
Flush 5
Daemon Off
Log_Level trace
Parsers_File parsers.conf
Plugins_File plugins.conf
HTTP_Server On
HTTP_Listen 0.0.0.0
HTTP_Port 2020
@git001
git001 / haproxy-sni.txt
Last active November 8, 2021 16:33
haproxy setup for sni routing
#---------------------------------------------------------------------
# Global settings
#---------------------------------------------------------------------
global
log stdout format raw daemon debug
log-send-hostname cloud.DOMAIN.com
maxconn 5000
ssl-default-bind-options ssl-min-ver TLSv1.0 no-tls-tickets
tune.ssl.default-dh-param 2048
@git001
git001 / softcover-build_pdf-error.txt
Created December 13, 2018 10:35
softcover build:pdf error
root@docinst:~/example_book# softcover build:pdf
Building PDF...
This is XeTeX, Version 3.14159265-2.6-0.99998 (TeX Live 2017/Debian) (preloaded format=xelatex)
restricted \write18 enabled.
entering extended mode
(./example_book.tmp.tex
LaTeX2e <2017-04-15>
Babel <3.18> and hyphenation patterns for 84 language(s) loaded.
(/usr/share/texlive/texmf-dist/tex/latex/extsizes/extbook.cls
Document Class: extbook 1999/01/07 v1.4a NON-Standard LaTeX document class
@git001
git001 / hosts-small.origin
Created August 17, 2018 17:36
Small okd ansible hosts file
[OSEv3:children]
masters
nodes
etcd
lb
glusterfs
[OSEv3:vars]
---
ffmpeg_bin: '/bin/ffmpeg'
profiles:
fullHDHighProfile: ' -r 30 -vcodec libx264 -pix_fmt yuv420p -crf 23 -s 1920x1080 -profile:v high -level 4 '
fullHD: ' -vcodec libx264 -pix_fmt yuv420p -crf 23 -s 1920x1080 '
HDready: ' -vcodec libx264 -pix_fmt yuv420p -crf 23 -s 1280x720 '
mobile: ' -vcodec libx264 -pix_fmt yuv420p -crf 23 -s 480x270 '
out_dir_base: '/home/videos'
out_dir_data: '/home/videos/transfer'
out_dir_snapshot_data: '/home/videos/transfer'
@git001
git001 / rh-atomic.json
Last active August 22, 2017 08:06
packer json file
{
"variables": {
"access_key": "",
"secret_key": "",
"ami": "ami-f9738680",
"osName": "RHEL-Atomic",
"osVersion" : "7.4",
"keypair": "Aleks",
"vpc": "vpc-xxx",
"subnet": "subnet-xxx",
@git001
git001 / provision.sh
Created August 22, 2017 07:55
The provision script
#!/bin/bash
if [[ ${DEBUG} ]]; then
set -x
sudo pvs
sudo vgs
sudo lvs
fi
# extend root partition
@git001
git001 / ansible-hosts-calico
Created August 15, 2017 09:48
Example inventory file for Calico SDN on openshift
# this is the ansible inventory file from
# https://youtu.be/FsXuZCEWEhQ
[OSEv3:children]
masters
nodes
etcd
[OSEv3:vars]
ansible_ssh_user=root
os_firewall_use_firewalld=false
oc get $(oc get secret -o name|egrep default-dockercfg) -o json
{
"kind": "Secret",
"apiVersion": "v1",
"metadata": {
"name": "default-dockercfg-6zf73",
"namespace": "aleks-test-auditd",
"selfLink": "/api/v1/namespaces/aleks-test-auditd/secrets/default-dockercfg-6zf73",
"uid": "1ecaf1d3-fe7c-11e6-94df-0a37fe677979",
"resourceVersion": "29345024",