Skip to content

Instantly share code, notes, and snippets.

View dscannell's full-sized avatar

David Scannell dscannell

View GitHub Profile
#!/bin/bash
# How to use: Pass to cloud-init as user data, or run as a script. When
# port 80 is open, your cloud is ready.
set -e
MYIP=`ifconfig eth1 | grep "inet addr" | awk -F: '{print $2}' | awk '{print $1}'`
HEADNODE=${1:-$MYIP}
#!/bin/bash
# How to use: Pass to cloud-init as user data, or run as a script. When
# port 80 is open, your cloud is ready.
set -e
MYIP=`ifconfig eth0 | grep "inet addr" | awk -F: '{print $2}' | awk '{print $1}'`
# Fix hosts
echo 127.0.0.1 $(hostname) | sudo tee -a /etc/hosts
@dscannell
dscannell / precise-grizzly-uca.sh
Last active December 19, 2015 01:59
Create an OpenStack Grizzly cluster on a ubuntu precise machine using the cloud archives. Cinder is used for volumes and nova-network for networking. Can be used to setup a headnode with Keystone / Glance / etc as well as adding additional compute nodes to the headnode. When adding compute nodes call the script with the headnode's ip address.
#!/bin/bash
# How to use: Pass to cloud-init as user data, or run as a script. When
# port 80 is open, your cloud is ready.
set -e
MYIP=`ifconfig eth1 | grep "inet addr" | awk -F: '{print $2}' | awk '{print $1}'`
HEADNODE=${1:-$MYIP}