Skip to content

Instantly share code, notes, and snippets.

@mikewadhera
Created November 22, 2010 21:19
Show Gist options
  • Save mikewadhera/710701 to your computer and use it in GitHub Desktop.
Save mikewadhera/710701 to your computer and use it in GitHub Desktop.
#!/bin/sh
echo 'Updating apt-get sources'
echo '
# Debian Lenny
deb http://ftp.debian.org/debian/ lenny main contrib non-free
deb-src http://ftp.debian.org/debian/ lenny main contrib non-free
deb http://http.us.debian.org/debian lenny main contrib non-free
# Debian Lenny Security Updates
deb http://security.debian.org lenny/updates main contrib non-free
# for packages in unstable
deb http://ftp.debian.org/debian/ unstable non-free
deb-src http://ftp.debian.org/debian/ unstable non-free
' > /etc/apt/sources.list && apt-get update
echo Installing Ruby...
echo ==================
apt-get install -y ruby1.8-dev ruby libzlib-ruby rdoc irb libopenssl-ruby1.8 ri irb build-essential wget
echo Installing RubyGems...
echo ======================
cd /tmp
wget http://production.cf.rubygems.org/rubygems/rubygems-1.3.7.tgz
tar zxvf rubygems-1.3.7.tgz
cd rubygems-1.3.7
ruby setup.rb
ln -sfv /usr/bin/gem1.8 /usr/bin/gem
echo Installing Chef...
echo ==================
gem sources -a http://gems.opscode.com
gem uninstall json --no-executables -I
gem install json --version=1.4.2 --no-ri --no-rdoc
gem install chef --version=0.6.2 --no-ri --no-rdoc
echo Chef installation complete.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment