Skip to content

Instantly share code, notes, and snippets.

@thbar
Created February 7, 2011 15:21
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save thbar/814522 to your computer and use it in GitHub Desktop.
Save thbar/814522 to your computer and use it in GitHub Desktop.
bash -c '
if [ ! -f /usr/local/lib/rvm ]; then
echo Boostrapping with RVM
apt-get update
apt-get install -y git-core curl
apt-get install -y build-essential binutils-doc gcc autoconf flex bison
apt-get install -y libreadline5-dev zlib1g-dev libssl-dev libxml2-dev libxslt1-dev
bash < <( curl -L http://bit.ly/rvm-install-system-wide )
(
cat <<'EOP'
[[ -s "/usr/local/lib/rvm" ]] && . "/usr/local/lib/rvm" # This loads RVM into a shell session.
EOP
) > /etc/profile.d/rvm.sh
source /etc/profile
rvm install 1.9.2-p136
rvm --default 1.9.2-p136
gem install chef -v=0.9.12 --no-rdoc --no-ri --verbose
ln -nfs $(which chef-client) /usr/bin/chef-client
ln -nfs $(which chef-solo) /usr/bin/chef-solo
else
echo Already bootstrapped with RVM
fi
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment