Skip to content

Instantly share code, notes, and snippets.

@ashrafuzzaman
Last active August 29, 2015 14:01
Show Gist options
  • Save ashrafuzzaman/f893ce3f567e5393d8c2 to your computer and use it in GitHub Desktop.
Save ashrafuzzaman/f893ce3f567e5393d8c2 to your computer and use it in GitHub Desktop.
Install ruby 2.1.2 in ubuntu servers
#!/bin/sh
sudo apt-get update
sudo apt-get install build-essential git-core curl sqlite3 libsqlite3-dev libxml2-dev libxslt1-dev libreadline-dev libyaml-dev libcurl4-openssl-dev libncurses5-dev libgdbm-dev libffi-dev imagemagick libmagickwand-dev wget
sudo aptitude purge ruby
sudo rm -rf /usr/bin/ruby
wget http://cache.ruby-lang.org/pub/ruby/2.1/ruby-2.1.2.tar.gz
tar -xvf ruby-2.1.2.tar.gz
cd ruby-2.1.2
./configure
make
make test
sudo make install
sudo gem install bundler
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment