Skip to content

Instantly share code, notes, and snippets.

Avatar
⛩️
Zazen

James Cuzella trinitronx

⛩️
Zazen
View GitHub Profile
View cluster-bug-reproduction.yaml
addons:
rescheduler:
enabled: false
clusterName: etcd-fail
controller:
autoScalingGroup:
maxSize: 3
minSize: 1
rollingUpdateMinInstancesInService: 2
count: 1
@trinitronx
trinitronx / blank-resin-data-hack.log
Last active Mar 12, 2017
ResinOS bitbake hack to get docker-custom-disk to build inside a docker-in-docker container (blank disk img)
View blank-resin-data-hack.log
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export WORKDIR=/src/resin-raspberrypi/build/tmp/work/raspberrypi3-poky-linux-gnueabi/docker-custom-disk/1.0-r0/
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export TARGET_REPOSITORY=${SUPERVISOR_REPOSITORY}
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export TARGET_TAG=v3.0.1
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export SUPERVISOR_REPOSITORY="resin/armv7hf-supervisor"
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export WORKDIR=/src/resin-raspberrypi/build/tmp/work/raspberrypi3-poky-linux-gnueabi/docker-custom-disk/1.0-r0/
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export SUPERVISOR_REPOSITORY="resin/armv7hf-supervisor"
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export TARGET_REPOSITORY=${SUPERVISOR_REPOSITORY}
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export TARGET_TAG=v3.0.1
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ export PARTITION_SIZE="1024"
bitbake@9854c74a3bbb:/src/resin-raspberrypi$ cd $WORKDIR
View kubectl-describe-pod-influxdb-monitoring.yaml
Name: monitoring-influxdb-123456789-ab123
Namespace: kube-system
Node: ip-12-34-56-78.ec2.internal/12.34.56.78
Start Time: Thu, 02 Mar 2017 13:07:11 -0700
Labels: k8s-app=influxdb
pod-template-hash=123456789
task=monitoring
Status: Running
Controllers: ReplicaSet/monitoring-influxdb-123456789
@trinitronx
trinitronx / pip_list_available_package_versions.py
Created Feb 7, 2017
Pip list all versions of a package that are available
View pip_list_available_package_versions.py
import json
import urllib2
from distutils.version import StrictVersion
from distutils.version import LooseVersion
def versions(package_name):
url = "https://pypi.python.org/pypi/%s/json" % (package_name,)
data = json.load(urllib2.urlopen(urllib2.Request(url)))
versions = data["releases"].keys()
try:
View gpg21_ChefSpec.log
.[2017-01-06T03:21:56-07:00] WARN: Invalid Ableton Live Option detected! Refusing to write this one to Options.txt!
[2017-01-06T03:21:56-07:00] WARN: Invalid Option: FooBarBazInvalid
[2017-01-06T03:21:56-07:00] WARN: Invalid Ableton Live Option detected! Refusing to write this one to Options.txt!
[2017-01-06T03:21:56-07:00] WARN: Invalid Option:
..[2017-01-06T03:21:56-07:00] WARN: AVID CoreAudio is installed! You may encounter problems with Native Instruments hardware and AVID drivers!
[2017-01-06T03:21:56-07:00] WARN: NI knows about this issue, for more information see: http://www.native-instruments.com/en/support/knowledge-base/show/3163/mac-os-x-10.10-yosemite-compatibility-news/
.[2017-01-06T03:21:56-07:00] WARN: AVID CoreAudio is installed! You may encounter problems with Native Instruments hardware and AVID drivers!
[2017-01-06T03:21:56-07:00] WARN: NI knows about this issue, for more information see: http://www.native-instruments.com/en/support/knowledge-base/show/3163/mac-os-x-10.10-yosemite-compatib
View cidr2regex.py
#!/usr/bin/python
''' Not my script, found on the Internet, and rediscovered on my hard drive
'''
import sys
def cidr_to_regex(cidr):
ip, prefix = cidr.split('/')
base = 0
for val in map(int, ip.split('.')):
@trinitronx
trinitronx / Dockerfile
Last active Oct 11, 2017
test-kitchen SystemD + DBus Dockerfile
View Dockerfile
FROM debian:8.1
RUN dpkg-divert --local --rename --add /sbin/initctl
RUN ln -sf /bin/true /sbin/initctl
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update
RUN apt-get install -y sudo openssh-server curl lsb-release
# test-kitchen user setup
@trinitronx
trinitronx / keybase-verify-signing-key-sig.sh
Last active May 25, 2020
Script to Verify My Software Signing Key & Keybase Identity
View keybase-verify-signing-key-sig.sh
#!/bin/bash
KEYBASE_USERID=trinitronx
GPG_PUBKEY_URL="https://keybase.io/trinitronx/key.asc"
SIGCHAIN_LINK="271330c45423cd997dafdc3f355c9575c0e6213aeb464596a457995ba0ae89110f"
THIS_SCRIPT_URL="https://gist.github.com/trinitronx/aee110cbdf55e67185dc44272784e694/raw/keybase-verify-signing-key-sig.sh"
THIS_SCRIPT_KEYBASE_SIGNATURE_URL="https://gist.github.com/trinitronx/aee110cbdf55e67185dc44272784e694/raw/keybase-verify-signing-key-sig.sh.keybase.sig.asc"
THIS_SCRIPT_GPG_SIGNATURE_URL="https://gist.github.com/trinitronx/aee110cbdf55e67185dc44272784e694/raw/keybase-verify-signing-key-sig.sh.gpg.sig.asc"
echo "This script requires that curl, gpg2, and jq are installed"
@trinitronx
trinitronx / gist:8b80f2e2529b9bc32bf70af01b59033a
Created Jun 10, 2016 — forked from clintel/gist:1155906
Fenced code in bullet lists with GitHub-flavoured MarkDown??
View gist:8b80f2e2529b9bc32bf70af01b59033a

Fenced code blocks inside ordered and unordered lists

  1. This is a numbered list.

  2. I'm going to include a fenced code block as part of this bullet:

    Code
    More Code
    
@trinitronx
trinitronx / gpg-agent.conf
Created May 12, 2016 — forked from nl5887/gpg-agent.conf
Using GPG Agent on OS-X
View gpg-agent.conf
launchctl unload -w -S Aqua /System/Library/LaunchAgents/gpg.agent.daemon.plist
launchctl load -w -S Aqua /System/Library/LaunchAgents/gpg.agent.daemon.plist
You can’t perform that action at this time.