I hereby claim:
- I am gauntletwizard on github.
- I am gauntletwizard (https://keybase.io/gauntletwizard) on keybase.
- I have a public key ASA3GF3F2JAd_WN9-svtXfeDHDvSu7WiLV1V2L0n01gw8Qo
To claim this, I am signing this object:
set -e | |
set -x | |
true | false |true | |
echo "done" | |
set -o pipefail | |
true | false ||true |
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/env python | |
# gceips.py - A script to print the cidr ranges of all of GCE. | |
# https://cloud.google.com/compute/docs/faq#where_can_i_find_short_product_name_ip_ranges | |
import re | |
# pip install dnspython | |
import dns.resolver | |
from dns.rdatatype import TXT | |
includesmatch = re.compile(r'include:([\w\.-]*)') |
# Find our image, and first and last images. | |
# Gimp GIF export animates from bottom to top, so these are backwards. | |
foo = gimp.image_list()[0] | |
start = foo.layers[0] | |
end = foo.layers[1] | |
start.visible = False | |
end.visible = False | |
# Step - How much we increase opacity each time. |
Read one link per day, mull on it, and ask clarifying questions from your local SRE
#!/bin/bash | |
# honeysave.sh - Saves honeycomb boards for version control purposes | |
WRITEKEY="" | |
honeycurl() { | |
curl -H "X-Honeycomb-Team: ${WRITEKEY}" https://api.honeycomb.io/1/boards/$* | |
} | |
save() { |
kubectl --context CLUSTER run --image ubuntu pgtool -- /bin/bash -c "apt-get update; apt-get install -y postgresql-client; sleep 86400" | |
kubectl --context gke_lido-staging_us-east1_lido-staging-us-east1 run --image redis redis -- /bin/bash -c "sleep 86400" |
set -eux -o pipefail | |
IAMUSER="$1" | |
aws iam create-user --user-name "${IAMUSER}" | |
POLICY="$(aws iam create-policy --policy-name "${IAMUSER}" --policy-document file://policy.json)" # "file://${IAMUSER}.policy" | |
ARN="$(echo $POLICY |jq -r .Policy.Arn)" | |
aws iam attach-user-policy --user-name "${IAMUSER}" --policy-arn="${ARN}" | |
# Create the access-key and parse the response to the ID and Secret | |
KEY="$(aws iam create-access-key --user-name "${IAMUSER}")" | |
KEYID="$(echo "${KEY}" |jq -r .AccessKey.AccessKeyId)" | |
KEYSECRET="$(echo "${KEY}" |jq -r .AccessKey.SecretAccessKey)" |
# Notes on connecting | |
# Trust the k8s root certificate | |
security -v add-trusted-cert -k "${HOME}/Library/Keychains/login.keychain-db" -r trustRoot "${KUBE_CERT}" | |
# Generate a user key and `security import` it | |
openssl genrsa -out "${CLIENTCERTKEY}" 4096 | |
security import "${CLIENTCERTKEY}" | |
# Set for OSX | |
# Get the sha | |
# security find-cert -a -c ted -Z |