This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-[.*/.*/?packer_cache/] | |
-[.*\.DS_Store] | |
-[.*\.tmp] | |
-[/home/.*/.ansible_async/] | |
-[/home/.*/.ansible/] | |
-[/home/.*/.atom/] | |
-[/home/.*/.cache/] | |
-[/home/.*/.config/Duplicati/] | |
-[/home/.*/.cups/] | |
-[/home/.*/.docker/] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- name: Install MacOS Packages | |
hosts: localhost | |
become: false | |
vars: | |
brew_cask_packages: | |
- atom | |
- docker | |
- dropbox | |
- firefox |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
ANSIBLE_VERSION=4.7.0 | |
apt-get update | |
apt-get -y install build-essential curl fontconfig libbz2-dev libffi-dev \ | |
libreadline-dev libsqlite3-dev libssl-dev python-is-python3 python3-dev \ | |
python3-minimal python3-pip python3-setuptools python3-virtualenv \ | |
python3-venv vim virtualenv zlib1g-dev zsh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import subprocess | |
from git import Repo | |
working_dir = os.getcwd() | |
repo = Repo(working_dir) | |
origin_branches = list() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Cisco ASA | |
filter { | |
if "syslog" in [tags] and "pre-processed" not in [tags] { | |
if "%ASA-" in [message] { | |
mutate { | |
add_tag => [ "pre-processed", "Firewall", "ASA" ] | |
} | |
grok { | |
match => [ | |
"message", "<%{POSINT:syslog_pri}>%{CISCOTIMESTAMP:timestamp} %{SYSLOGHOST:sysloghost} %%{CISCOTAG:cisco_tag}: %{GREEDYDATA:cisco_message}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
input { | |
file { | |
path => "/var/log/nginx/access.log" | |
type => "nginx-access" | |
sincedb_path => "/var/log/.nginxaccesssincedb" | |
} | |
} | |
input { | |
file { | |
path => "/var/log/nginx/error.log" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
# Most pre-req tooling, etc. is installed using jumphosts.yml playbook | |
variables: | |
ADMIN_EMAIL: mrlesmithjr@gmail.com | |
CLOUD_PROVIDER: Azure # Define Supported Cloud Provider (Azure) | |
GIT_CRYPT_ENABLED: "true" # Must be lowercase (true|false) | |
GIT_SUBMODULE_STRATEGY: recursive | |
ORGANIZATION: example_org | |
PROJECT_NAME: example_project | |
TERRAFORM_VERSION: 0.12.28 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# This is not an ideal solution (currently) to export into production/development specific | |
# requirements. | |
# Capture current system time | |
CURRENT_TIME=$(date +"%Y.%m.%d-%H.%M.%S") | |
# Capture all Python packages currently installed | |
pip3 list --not-required --format freeze --exclude lockfile --exclude pip --exclude setuptools >"requirements.txt.${CURRENT_TIME}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ansible managed | |
global | |
# Remote syslog servers | |
log 10.0.102.102:514 local0 | |
#log-send-hostname | |
daemon | |
chroot /var/lib/haproxy | |
group haproxy | |
maxconn 40000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# flush_dns.py | |
'''A handy script to flush dns cache for Linux/macOS/Windows.''' | |
import logging | |
from subprocess import Popen | |
from sys import platform | |
import psutil |
NewerOlder