Skip to content

Instantly share code, notes, and snippets.

@hartzell
hartzell / aurora_cluster.tf
Last active April 6, 2020 16:11 — forked from sandcastle/aurora_cluster.tf
Creates a AWS RDS Aurora Cluster with Terraform
########################
## Variables
########################
variable "environment_name" {
description = "The name of the environment"
}
variable "vpc_id" {
@hartzell
hartzell / app-init.sh
Created January 16, 2019 23:42
A script to initialize a user's environment to use a tree of Spack packages
# -*- mode: sh -*-
# vim: set ft=sh
#
# The typical user's .bash_profile would include:
#
# APPS_MODULES="emacs git htop the-silver-searcher" # and etc....
# source /moose/apps/init.sh
#
# Even setting APPS_MODULES is optional if user is ok with default list...
#
@hartzell
hartzell / session.md
Created January 27, 2019 01:37
Adding local networks for Plex in jail
root@helium[/mnt/storage/home/hartzell]# cat /mnt/storage/iocage/jails/plex/root/Plex\ Media\ Server/Preferences.xml
<?xml version="1.0" encoding="utf-8"?>
<Preferences OldestPreviousVersion="1.14.1.5488-cc260c476" MachineIdentifier="7cd0df33-f7a9-48bc-a855-1ea65f46f8b0" ProcessedMachineIdentifier="85517e6e530782f318f9b9b6de5c76baabba18d6" AnonymousMachineIdentifier="514d266b-4d7e-41b0-b1de-935bcc00e5e5" MetricsEpoch="1" allowedNetworks="192.168.42.0/255.255.255.0" AcceptedEULA="1" FriendlyName="helium-plex" PublishServerOnPlexOnlineKey="1" LastAutomaticMappedPort="0"/>
@hartzell
hartzell / doit.sh
Created February 4, 2019 03:38
Quick/dirty poudriere config to build audio/logitechmediaserver
cp usr_local_etc_poudriere.d_make.conf /usr/local/etc/poudriere.d/make.conf
cp usr_local_etc_poudriere.conf /usr/local/etc/poudriere.conf
echo 'audio/logitechmediaserver' > ./pkglist
sudo mkdir /usr/ports/distfiles
sudo zfs create zroot/poudriere
sudo poudriere jail -c -j 11amd64 -v 11.2-RELEASE
sudo poudriere ports -c -p local
sudo poudriere bulk -f ./pkglist -j 11amd64 -p local
@hartzell
hartzell / doit.sh
Created February 4, 2019 03:38
Quick/dirty poudriere config to build audio/logitechmediaserver
cp usr_local_etc_poudriere.d_make.conf /usr/local/etc/poudriere.d/make.conf
cp usr_local_etc_poudriere.conf /usr/local/etc/poudriere.conf
echo 'audio/logitechmediaserver' > ./pkglist
sudo mkdir /usr/ports/distfiles
sudo zfs create zroot/poudriere
sudo poudriere jail -c -j 11amd64 -v 11.2-RELEASE
sudo poudriere ports -c -p local
sudo poudriere bulk -f ./pkglist -j 11amd64 -p local
@hartzell
hartzell / step-by-step.md
Last active April 24, 2019 02:10
Spack singularity package debugging session

I've fetched/merged your branch and am at commit ec296438fd41b18ea310ea83acf534e8f295a25a.

Here is the definition of source_path for a stage:

Here's the interesting bit, it's returning the first thing that it finds in the output of os.listdir that is a directory (order of things returned by listdir is unspecified):

@hartzell
hartzell / udev
Last active May 20, 2019 17:54
Amazon Linux udev rules
# Copyright (C) 2006-2016 Amazon.com, Inc. or its affiliates.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License").
# You may not use this file except in compliance with the License.
# A copy of the License is located at
#
# http://aws.amazon.com/apache2.0/
#
# or in the "license" file accompanying this file. This file is
@hartzell
hartzell / .lircrc-A1156
Last active January 19, 2021 11:42
Configuring a headless PiCorePlayer to use an Apple 1294 IR remote
begin
remote = Apple_A1156
button = KEY_UP
repeat = 0
prog = squeezelite
config = volup
end
begin
remote = Apple_A1156
@hartzell
hartzell / simple-spack-install.sh
Created December 3, 2019 16:49
Simplified version of a script for providing a big bunch of things with Spack
#!/bin/sh
set -e
# having an app tree set up messes up the build. Clear the field.
if [[ $(type -t module) == "function" ]]; then
module purge
fi
cat << "EOYAML" > etc/spack/packages.yaml
packages:
@hartzell
hartzell / failing-test-case.md
Last active January 29, 2020 00:30
Demo of failing and working cases of connecting to files.pythonhosted.org
(alice)[16:00:11]~>>/usr/bin/openssl s_client -connect files.pythonhosted.org:443
CONNECTED(00000005)
depth=1 C = BE, O = GlobalSign nv-sa, CN = GlobalSign CloudSSL CA - SHA256 - G3
verify error:num=20:unable to get local issuer certificate
verify return:0
---
Certificate chain
 0 s:/C=US/ST=California/L=San Francisco/O=Fastly, Inc/CN=r.ssl.fastly.net
   i:/C=BE/O=GlobalSign nv-sa/CN=GlobalSign CloudSSL CA - SHA256 - G3