Skip to content

Instantly share code, notes, and snippets.

@jinoj
jinoj / vscode
Created February 12, 2020 14:14
-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'Ubuntu', 'Droid Sans', sans-serif
Consolas, 'Courier New', monospace
@jinoj
jinoj / ansible-summary.md
Created December 18, 2018 10:06 — forked from andreicristianpetcu/ansible-summary.md
This is an ANSIBLE Cheat Sheet from Jon Warbrick

An Ansible summary

Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)

Configuration file

intro_configuration.html

First one found from of

@jinoj
jinoj / ansible.cfg
Created December 8, 2018 16:34 — forked from nazarewk/ansible.cfg
Ansible SSH Agent forwarding with Jump (bastion) host
[defaults]
sudo_flags = SSH_AUTH_SOCK="$SSH_AUTH_SOCK" -H -S -n
[ssh_connection]
ssh_args=-o ForwardAgent=yes
@jinoj
jinoj / testrsync.yml
Created September 24, 2018 05:34 — forked from tima/testrsync.yml
A playbook for testing of ansible-rsync
---
-
hosts: remote_host
gather_facts: no
name: "Testing synchronize"
vars:
start_time: "{{ lookup('pipe','date') }}"
test_files:
- test1
- test2
# This gist is compatible with Ansible 1.x .
# For Ansible 2.x , please check out:
# - https://gist.github.com/dmsimard/cd706de198c85a8255f6
# - https://github.com/n0ts/ansible-human_log
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
@jinoj
jinoj / debian_upgrade.yml
Created September 18, 2018 07:04 — forked from maethor/debian_upgrade.yml
Ansible playbook to update and upgrade Debian hosts
---
- hosts: all
sudo: yes
tasks:
- name: Update packages list
apt: update_cache=yes
when: ansible_os_family == 'Debian'
- name: List packages to upgrade (1/2)
@jinoj
jinoj / vim_cheatsheet.md
Created July 4, 2018 05:13 — forked from awidegreen/vim_cheatsheet.md
Vim shortcuts

Introduction

  • C-a == Ctrl-a
  • M-a == Alt-a

General

:q        close
:w        write/saves
:wa[!]    write/save all windows [force]
:wq       write/save and close
@jinoj
jinoj / squid.conf
Created June 19, 2018 11:16 — forked from hpcorona/squid.conf
simple squid3 configuration to allow all to connect to all
#Recommended minimum configuration:
acl manager proto cache_object
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8
acl localnet src 0.0.0.0/8 192.168.100.0/24 192.168.101.0/24
acl SSL_ports port 443
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 # https
acl Safe_ports port 70 # gopher
@jinoj
jinoj / haproxy-ssl.cfg
Created June 19, 2018 10:10 — forked from TJkrusinski/haproxy-ssl.cfg
HAProxy SSL Setup Redirect non HTTPS traffic to HTTPS and terminate SSL
# Basic file, has no logging or anything else setup
global
maxconn 20000
defaults
mode http
timeout connect 5000ms
timeout client 50000ms
timeout server 50000ms
@jinoj
jinoj / gist:ffe2b13e38df3ad21132b06cc3bb9e27
Created June 19, 2018 07:35 — forked from jayjanssen/gist:4039319
sysctl tuning for HAproxy
net.core.somaxconn = 32768
net.ipv4.conf.all.send_redirects = 1
net.ipv4.ip_nonlocal_bind = 1
net.ipv4.tcp_abort_on_overflow = 0
net.ipv4.tcp_fin_timeout = 10
net.ipv4.tcp_keepalive_time = 300
net.ipv4.tcp_max_orphans = 262144
net.ipv4.tcp_max_syn_backlog = 16384
net.ipv4.tcp_max_tw_buckets = 262144
net.ipv4.tcp_mem = 200000    280000    300000