Skip to content

Instantly share code, notes, and snippets.

@mikeplate
Created November 15, 2011 19:54
Show Gist options
  • Save mikeplate/1368122 to your computer and use it in GitHub Desktop.
Save mikeplate/1368122 to your computer and use it in GitHub Desktop.
Set up Ruby, Passenger and Nginx
#!/bin/bash
if [ "$(whoami)" != "root" ]; then
echo "Run as root!"
exit 1
fi
apt-get -y install curl git build-essential bison openssl libreadline5 libreadline-dev
apt-get -y install zlib1g zlib1g-dev libssl-dev libsqlite3-0 libsqlite3-dev sqlite3
apt-get -y install libreadline-dev libxml2-dev autoconf libtool
bash < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer )
source "$HOME/.rvm/scripts/rvm"
rvmcheck="rvm is a function"
if [[ `type rvm | head -n1` != "$rvmcheck" ]]; then
echo "RVM install problem. RVM must be a function!"
exit 1
fi
rvm install 1.9.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment