Last active
December 15, 2015 20:33
-
-
Save winhamwr/3bad9f4e05885b599a4e to your computer and use it in GitHub Desktop.
PolicyStat Ubuntu dev machine setup
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Gist available at: https://gist.github.com/winhamwr/3bad9f4e05885b599a4e | |
set -e; | |
export JOB_IDLE_TIMEOUT=60 | |
make --makefile=$WORKSPACE/scripts/hudson/Makefile log_job_started_for_idle_shutdown; | |
sudo apt-get update; | |
sudo apt-get install -y; | |
sudo apt-get install -y build-essential linux-headers-$(uname -r) nfs-kernel-server dkms dpkg-dev; | |
# Install chefdk | |
wget --timestamping https://opscode-omnibus-packages.s3.amazonaws.com/ubuntu/12.04/x86_64/chefdk_0.10.0-1_amd64.deb; | |
sudo dpkg --install chefdk_0.10.0-1_amd64.deb; | |
# Install Vagrant and Vagrant plugins | |
wget --timestamping https://releases.hashicorp.com/vagrant/1.7.4/vagrant_1.7.4_x86_64.deb; | |
sudo dpkg --install vagrant_1.7.4_x86_64.deb; | |
vagrant plugin install vagrant-omnibus --plugin-version 1.4.1 | |
vagrant plugin install vagrant-cachier --plugin-version 0.7.2 | |
vagrant plugin install vagrant-berkshelf --plugin-version 4.1.0 | |
# Install Virtualbox using the PPA | |
# Add Oracle's release key for the Virtualbox PPA | |
wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add - | |
#sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian precise contrib" > /etc/apt/sources.list.d/virtualbox.list' | |
sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian trusty contrib" > /etc/apt/sources.list.d/virtualbox.list' | |
sudo apt-get update; | |
sudo apt-get install -y virtualbox-5.0; | |
sudo /etc/init.d/vboxdrv setup; | |
# Install the virtualbox extension pack | |
wget --timestamping http://download.virtualbox.org/virtualbox/5.0.10/Oracle_VM_VirtualBox_Extension_Pack-5.0.10-104061.vbox-extpack; | |
set +e; # If the extpack is already installed, the command exits 1 | |
sudo VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-5.0.10-104061.vbox-extpack; | |
# Clean up any previous vagrant box builds, if any | |
vagrant halt --force dev; | |
vagrant destroy --force dev; | |
set -e; | |
# Build the Vagrant box | |
berks | |
VAGRANT_VBOX_MEMORY=1000 VAGRANT_VBOX_CPU=1 VAGRANT_LOG=info vagrant up dev |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment