Skip to content

Instantly share code, notes, and snippets.

@jcarley
Last active February 18, 2022 22:23
Show Gist options
  • Save jcarley/edd0da8d78ab17fa1900c7531e28ba69 to your computer and use it in GitHub Desktop.
Save jcarley/edd0da8d78ab17fa1900c7531e28ba69 to your computer and use it in GitHub Desktop.
# install rbenv on Amazon Linux
# first we need some prerequisites
sudo yum install -y git gcc make readline-devel openssl-devel
# now install rbenv
git clone git://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
source ~/.bashrc
# finally install ruby-build
mkdir -p "$(rbenv root)"/plugins
git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
# don't download documentation when install gems
echo 'gem: --no-document' >> ~/.gemrc
# upgrade rubygems
gem update --system
# now install bundler
gem install bundler
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment