This file contains hidden or 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
FROM debian:stretch-slim | |
RUN mkdir -p /srv/hny && \ | |
apt-get update && \ | |
apt-get install -y ca-certificates openssl bzip2 | |
WORKDIR /srv/hny | |
# Need to build with tarball (provided by HNY team) adjacent in docker build directory | |
COPY st.tbz st.tbz | |
RUN tar --strip-components 1 -xjf st.tbz && \ |
This file contains hidden or 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
from ipaddress import ip_network, ip_address | |
import json | |
import requests | |
import sys | |
def find_aws_region(): | |
ip_json = requests.get('https://ip-ranges.amazonaws.com/ip-ranges.json') | |
#ip_json = json.load(open('ip-ranges.json')) | |
ip_json = ip_json.json() | |
prefixes = ip_json['prefixes'] |
This file contains hidden or 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
MY_INSTANCEID | |
MY_SERVER | |
user-data.txt | |
.zshrc | |
.gitconfig | |
.ssh | |
.byobu | |
.oh-my-zsh |
This file contains hidden or 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
[Unit] | |
Description=Demonstrate Bash | |
[Service] | |
ExecStartPre=/usr/bin/bash -c "/usr/bin/systemctl set-environment MYVAR=$(( 2 + 2 ))" | |
ExecStart=/usr/bin/echo "2 + 2 = ${MYVAR}" |
This file contains hidden or 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
# A sample Guardfile | |
# More info at https://github.com/guard/guard#readme | |
guard 'kitchen' do | |
watch(%r{test/.+}) | |
watch(%r{^recipes/(.+)\.rb$}) | |
watch(%r{^attributes/(.+)\.rb$}) | |
watch(%r{^files/(.+)}) | |
watch(%r{^templates/(.+)}) | |
watch(%r{^providers/(.+)\.rb}) |