Skip to content

Instantly share code, notes, and snippets.

View phillhocking's full-sized avatar

Phillip Andrew Hocking phillhocking

View GitHub Profile
@phillhocking
phillhocking / patchbay.sh
Created December 24, 2021 04:37
Pulse/Jack/Carla Automation Script (Assumes Audiobox USB96 but if you are dumb enough to be trying this figure out yourself with pulsectl)
#!/bin/bash
# Start Jack daemon
jack_control start
# Jack -> Pulse return
PAM1=$(pactl load-module module-jack-source source_name=pulse_return client_name=pulse_return connect=false)
# Pulse return source -> Sink loopback
PAM2=$(pactl load-module module-loopback sink=alsa_output.usb-PreSonus_AudioBox_USB_96_000000000000-00.analog-stereo source=pulse_return source_dont_move=true sink_dont_move=true)
@phillhocking
phillhocking / mate-vimix.sh
Last active December 29, 2021 20:47
Stand Up Ubuntu Studio 20.04 with NVIDIA CUDA/nvenc ffmpeg
#!/bin/bash
# personalization/visualization
gsettings set com.canonical.indicator.datetime time-format '24-hour'
sudo add-apt-repository ppa:papirus/papirus -y && sudo apt update
sudo apt install -y papirus-icon-theme git sassc python3-pip fonts-powerline powerline
pip install powerline-status
pip3 install powerline-gitstatus
git clone https://github.com/vinceliuice/vimix-gtk-themes.git vimix
cd vimix
@phillhocking
phillhocking / config
Created July 28, 2021 07:16
Default irssi config for Ubuntu 20.04 1.2.2-1ubuntu1.1
servers = (
{ address = "irc.dal.net"; chatnet = "DALnet"; port = "6667"; },
{ address = "ssl.efnet.org"; chatnet = "EFNet"; port = "9999"; use_tls = "yes"; },
{ address = "irc.esper.net"; chatnet = "EsperNet"; port = "6697"; use_tls = "yes"; tls_verify = "yes"; },
{ address = "chat.freenode.net"; chatnet = "Freenode"; port = "6697"; use_tls = "yes"; tls_verify = "yes"; },
{ address = "irc.gamesurge.net"; chatnet = "GameSurge"; port = "6667"; },
{ address = "eu.irc6.net"; chatnet = "IRCnet"; port = "6667"; use_tls = "yes"; },
{ address = "open.ircnet.net"; chatnet = "IRCnet"; port = "6667"; },
{ address = "irc.ircsource.net"; chatnet = "IRCSource"; port = "6667"; },
{ address = "irc.netfuze.net"; chatnet = "NetFuze"; port = "6667"; },
@phillhocking
phillhocking / main.tf
Last active July 27, 2021 15:06
AWS VPC Module
data "aws_availability_zones" "available" {
state = "available"
}
locals {
aws_available_zones = data.aws_availability_zones.available.names[0]
}
resource "aws_vpc" "main" {
cidr_block = var.cidr_block
@phillhocking
phillhocking / cloudinit.yml
Created July 14, 2021 04:41
cloudinit.yml file for phillhocking/aws-ubuntu-tig repo
#cloud-config
packages:
- apt-transport-https
- ca-certificates
- curl
- gnupg-agent
- software-properties-common
- git
# apt-get update, instantiate production TIG stack pinned to stable versions as of 7/13/2021
@phillhocking
phillhocking / tig.sh
Last active May 24, 2022 07:57
Instantiate TIG stack on Ubuntu 20.04
sudo apt update ; sudo apt install -y build-essential net-tools curl git software-properties-common
wget https://dl.influxdata.com/telegraf/releases/telegraf_1.19.1-1_amd64.deb
sudo dpkg -i telegraf_1.19.1-1_amd64.deb
sudo systemctl enable --now telegraf
wget https://dl.influxdata.com/influxdb/releases/influxdb_1.8.6_amd64.deb
sudo dpkg -i influxdb_1.8.6_amd64.deb
sudo systemctl enable --now influxdb
influx -execute 'create database telegraf'
influx -execute "create user telegraf with password 'ExAmPl3PA55W0rD'"
influx -execute 'grant all on telegraf to telegraf'
phocking@phocking-ws:/mnt/c/Users/phillip.hocking/Workspace/hubsub.io$ make deps
git clone --single-branch \
                  --branch amplify \
                  git@github.com:masterpointio/terraform-provider-aws.git \
                  ./tmp/terraform-provider-aws
Cloning into './tmp/terraform-provider-aws'...
remote: Enumerating objects: 133542, done.
remote: Counting objects: 100% (135/135), done.
remote: Compressing objects: 100% (135/135), done.
@phillhocking
phillhocking / salt-bootstrapper.ps1
Last active April 30, 2021 02:34
Windows salt-minion Bootstrapper
Set-ExecutionPolicy Bypass -Scope Process -Force; mkdir c:\temp\; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; (New-Object Net.WebClient).DownloadFile('https://winbootstrap.saltproject.io', 'c:\temp\bootstrap-salt.ps1'); c:\temp\bootstrap-salt.ps1 -minion win10_dev -master salt-dev

Keybase proof

I hereby claim:

  • I am phillhocking on github.
  • I am phillhocking (https://keybase.io/phillhocking) on keybase.
  • I have a public key whose fingerprint is 97BD E2F4 8F35 B412 4F47 33B8 26EB 8D36 3F08 53A1

To claim this, I am signing this object:

@phillhocking
phillhocking / cloudinit.yml
Last active November 23, 2021 19:05
netbox-aws
#cloud-config
packages:
- apt-transport-https
- ca-certificates
- curl
- gnupg-agent
- software-properties-common
- git
# create the docker group