I hereby claim:
- I am atward on github.
- I am atward (https://keybase.io/atward) on keybase.
- I have a public key whose fingerprint is DCF7 1D93 BE2C E24D CC64 62AD 5795 E6B4 8B33 50F2
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
#cloud-init | |
# https://docs.chef.io/packages.html#enterprise-linux | |
# vendor chef-repo to /var/lib/chef with cookbooks in /var/lib/chef/cookbooks | |
yum_repos: | |
chef-stable: | |
name: chef-stable | |
baseurl: https://packages.chef.io/stable-yum/el/7/\$basearch/ | |
enabled: true | |
failovermethod: priority |
#!/usr/bin/env bash | |
# Script to download asset file from tag release using GitHub API v3. | |
# See: http://stackoverflow.com/a/35688093/55075 | |
# Check dependencies. | |
set -e | |
type curl grep sed tr >&2 | |
# Validate settings. | |
[ "$GITHUB_API_TOKEN" ] || { echo "Error: Please define GITHUB_API_TOKEN variable." >&2; exit 1; } |
def safeget(dct, *keys): | |
dct = dict(dct) | |
for key in keys: | |
try: | |
dct = dct[key] | |
except (KeyError, AttributeError, TypeError) as e: | |
return None | |
return dct |
#!/usr/bin/env python3 | |
import os | |
import json | |
from pprint import pprint | |
import boto3 | |
# theme based off https://github.com/magicmonty/bash-git-prompt/blob/a2182bb646987ebca978a655a5deb18bcc65dbe1/themes/Single_line_Solarized.bgptheme | |
define_helpers() { | |
: | |
} | |
# Get git relative path | |
function prompt_callback { | |
if [[ -e "$repo" ]]; then | |
GitBaseName="${repo##*/}" |
# add memcache (Memorystore) example to development | |
resource "google_memcache_instance" "cache_dev" { | |
provider = google-beta | |
project = google_project.development.project_id | |
name = "cache-dev" | |
region = var.region | |
authorized_network = google_service_networking_connection.private_service_connection.network | |
node_config { | |
cpu_count = 1 |
module "http_lb" { | |
source = "GoogleCloudPlatform/lb-http/google" | |
version = "~> 4.5" | |
project = var.project_id | |
name = "demo" | |
http_forward = false | |
ssl = true | |
private_key = tls_private_key.example.private_key_pem |
#!/bin/bash | |
# source: https://gist.github.com/atward/7a2eb1b4a78fbaebe585 | |
# here be dragons: this is as dangerous as it looks | |
## terraform variable defaults | |
# takes *.tf and assigns env=default (if any) | |
# - map not supported (obvious reasons) | |
# - Tested on Darwin sed(1) only | |
function source_tfdefaults() { | |
eval "$( |
#!/usr/bin/env python | |
import boto3 | |
import json | |
import sys | |
import urllib2 | |
import webbrowser | |
from urllib import urlencode |