Skip to content

Instantly share code, notes, and snippets.

View apollocatlin's full-sized avatar

Apollo Catlin apollocatlin

View GitHub Profile
@sairez
sairez / get_secrets.yml
Created November 13, 2015 22:15
grabbing text from json file in an encrypted s3 bucket
- name: get secrets from s3 file
hosts: localhost
connection: local
gather_facts: False
tasks:
- name: grab json from encrypted S3 bucket
s3:
bucket: 'demo-bucket'
object: 'test.json'
aws_access_key: "{{lookup('env', 'AWS_ACCESS_KEY_ID')}}"
@darron
darron / default_ami_setup.sh
Last active September 5, 2017 14:31
Ubuntu 14.04 AWS Instance Store HVM build - actually worked - built and booted. Much thanks to: https://github.com/Lumida/packer/wiki/Building-Ubuntu-12.04-and-14.04-HVM-Instance-Store-AMIs
#!/bin/bash
# server-jre-8u5-linux-x64.tar.gz
DEBIAN_FRONTEND=noninteractive
UCF_FORCE_CONFFNEW=true
export UCF_FORCE_CONFFNEW DEBIAN_FRONTEND
apt-get update
apt-get -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confnew" dist-upgrade
@srgvg
srgvg / util-bash-vuln-upgrade.yml
Last active August 16, 2019 13:35
deb playbook to fix CVE-2014-6271 bash remote execution vulnerability
---
- hosts: all
gather_facts: false
name: CVE-2014-6271 bash vulnerability fix
tasks:
- name: check bash fix
command: env x='() { :;}; echo vulnerable' bash -c "echo this is a test"
register: command_result
changed_when: False
@labrown
labrown / elasticsearch-handlers-main.yml
Last active September 22, 2023 12:11
Ansible rolling restart of Elasticsearch Cluster
---
###
# Elasticsearch Rolling restart using Ansible
###
##
## Why is this needed?
##
#
# Even if you use a serial setting to limit the number of nodes processed at one
@denji
denji / README.md
Last active April 26, 2024 18:09 — forked from istepanov/gist:3950977
Remove/Backup – settings & cli for macOS (OS X) – DataGrip, AppCode, CLion, Gogland, IntelliJ, PhpStorm, PyCharm, Rider, RubyMine, WebStorm
#!/bin/bash
set -o errexit
# Author: David Underhill
# Script to permanently delete files/folders from your git repository. To use
# it, cd to your repository's root and then run the script with a list of paths
# you want to delete, e.g., git-delete-history path1 path2
if [ $# -eq 0 ]; then
exit 0
@agnoster
agnoster / README.md
Last active April 6, 2024 22:35
My ZSH Theme

agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

For Mac users, I highly recommend iTerm 2 + Solarized Dark

@tankchintan
tankchintan / gist:1335220
Last active November 30, 2019 00:17
Procedure for installing and setting Sun JDK Java on Default Amazon Linux AMI
# First verify the version of Java being used is not SunJSK.
java -version
# Get the latest Sun Java SDK from Oracle http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u1-download-513651.html
wget http://download.oracle.com/otn-pub/java/jdk/7u1-b08/jdk-7u1-linux-i586.rpm
# Rename the file downloaded, just to be nice
mv jdk-7u1-linux-i586.rpm\?e\=1320265424\&h\=916f87354faed15fe652d9f76d64c844 jdk-7u1-linux-i586.rpm
# Install Java