Skip to content

Instantly share code, notes, and snippets.

View network-shark's full-sized avatar
🌴
On vacation

sharky__¯\_(ツ)_/¯ network-shark

🌴
On vacation
View GitHub Profile
@JustinCarmony
JustinCarmony / example_output.txt
Created July 30, 2014 20:24
Summary Salt Highstate Outputter
root@deployServer:~# salt \* state.highstate --output=summary_highstate
web-server01.example.com ------------------ Success: 20 Changed: 0 Errors: 0
web-server02.example.com ------------------ Success: 71 Changed: 1 Errors: 0
db-server03.example.com ------------------- Success: 73 Changed: 1 Errors: 0
mongo-server04.example.com ---------------- Success: 74 Changed: 1 Errors: 0
mongo-server05.example.com ---------------- Success: 74 Changed: 1 Errors: 0
memcache-server06.example.com ------------- Success: 74 Changed: 1 Errors: 0
mysql-server07.example.com ---------------- Success: 74 Changed: 1 Errors: 0
logs-server08.example.com ----------------- Success: 20 Changed: 0 Errors: 0
redis-server09.example.com ---------------- Success: 27 Changed: 0 Errors: 0
@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@andreicristianpetcu
andreicristianpetcu / ansible-summary.md
Created May 30, 2016 19:25
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

@nazarewk
nazarewk / ansible.cfg
Last active August 2, 2021 20:27
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
@bsdlme
bsdlme / vagrant-bhyve.md
Last active May 7, 2024 12:21
Setting up vagrant-bhyve on FreeBSD

Using bhyve with vagrant

The following describes how to set up bhyve with Vagrant using the vagrant-bhyve plugin.

Prerequisites

@ammgws
ammgws / edgerouter_lite_openvpn.md
Last active April 16, 2023 05:04
Notes on setting up OpenVPN on Edgerouter Lite

My notes on how I setup OpenVPN server on Edgerouter Lite. Based mostly on this guide from openVPN wiki. This guide assumes easyrsa3 is being used, otherwise substitute whatever the easyrsa2 versions are for the commands below.

This guide will use 3 different machines.

A Public Key Infrastructure (PKI) will be created on each machine:

    1. Server - openVPN server (Edgerouter in this case).
    1. Client(s) - the device(s) you will be connecting from.
    1. CA Server - used to generate and sign certificates for server and clients to use.
@danielmacuare
danielmacuare / nornir.md
Last active October 11, 2023 10:55
Simple tutorial to use nornir for network automation solutions. The tutorial explain some basics to start with.

Nornir - Tutorial

https://nornir.readthedocs.io/en/stable/index.html

1 - Initialise a Nornir Object.

  r = InitNornir(config_file='config.yaml')
  nr = InitNornir(config_file='config.yaml', core={'num_workers': 1})		# Useful for testing as it works in serial, doesn't paralellise connections.

2 - Filtering Objects - Can be cumulative.