Create a gist now

Instantly share code, notes, and snippets.

Bootstrap Chef Solo. Usage: `curl -L | bash`
#!/usr/bin/env bash
# Tested for Ubuntu 12.04
# usage: `curl -L | bash`
# check for root permissions
[[ "$(id -u)" -ne "0" ]] && echo 'must be root!' && exit 1
echo -n 'Refreshing APT-Repos... '
apt-get update -qq && echo 'done!'
echo 'Install some dependencies... '
apt-get install -yq ruby1.9.3 build-essential
echo 'Install chef...'
gem install chef --no-ri --no-rdoc
mkdir -p /var/chef/cache
echo "done! Version:"
chef-solo -v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment