Skip to content

Instantly share code, notes, and snippets.

View tombarron's full-sized avatar
🏠

Tom Barron tombarron

🏠
  • Saxapahaw North Carolina
View GitHub Profile
@tombarron
tombarron / virt-install-xenial
Created February 1, 2017 20:08
script to install a VM for use as devstack host
#!/bin/bash
## Derives from: http://giovannitorres.me/create-a-linux-lab-on-kvm-using-cloud-images.html
## Assumes you have a xenial cloud image in $DIR below, via e.g.
# wget https://cloud-images.ubuntu.com/xenial/current/xenial-server-cloudimg-amd64-disk1.img
# Take one argument from the commandline: VM name
if ! [ $# -eq 1 ]; then
echo "Usage: $0 <node-name>"
@tombarron
tombarron / 12-getv6addr
Created August 3, 2020 12:20
Install this script as /etc/NetworkManager/dispatcher.d/12-getv6addr as a hack to get NM to acquire DHCPv6 stateful addresses at boot time
#!/bin/bash
set -x
DEVICE=$1
ACTION=$2
#if [[ $DEVICE = "eth1" && $ACTION = "up" ]] ; then
if [[ $ACTION = "up" ]]; then
MYNAME=$(echo $0 | awk -F '/' '{print $NF}')
WORKDIR=$(mktemp -d /var/tmp/${MYNAME}XXXX)