Created
December 1, 2013 04:28
-
-
Save JesseHerrick/7728497 to your computer and use it in GitHub Desktop.
Install RBEnv on EC2
This file contains hidden or 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
# Become sudo | |
sudo su - | |
# Update | |
yum update | |
# Install git for RBEnv and gcc for Ruby. | |
yum install git gcc | |
git clone git://github.com/sstephenson/rbenv.git /usr/local/rbenv | |
# Create /etc/profile.d/rbenv.sh | |
touch /etc/profile.d/rbenv.sh | |
cat <<EOF > /etc/profile.d/rbenv.sh | |
export RBENV_ROOT=/usr/local/rbenv | |
export PATH="${RBENV_ROOT}/bin:$PATH" | |
eval "$(rbenv init -)" | |
EOF | |
. /etc/profile | |
# Download rubybuild | |
git clone https://github.com/sstephenson/ruby-build.git /usr/local/rbenv/plugins/ruby-build | |
# Now install Ruby. | |
rbenv install 2.0.0-p353 | |
rbenv global 2.0.0-p353 | |
rbenv rehash |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment