1. Fist make sure your system is up to date
1
yum update -y
2. Then you need to install the development tools needed:
1
yum groupinstall -y development
3.Download and install rvm with curl
1
curl -L get.rvm.io | bash -s stable
4. Setup the system environment using rvm shell script:
1
source /etc/profile.d/rvm.sh
5. Now it’s time to install ruby I’m installing ruby 2.1.2
1
2
rvm get head
rvm install 2.1.2
Note:
you can get a error saying:
‘Error installing EPEL, it is required for libyaml-devel,
either there was an error installing EPEL package,
or there was problem checking if libyaml-devel is available / installed.’ Usually you can ignore this and run the rvm install 2.1.2 again.
if you are unsure if libyaml-devel is installed you can check this by typing:
1 yum info libyaml-devel
**6. Check ruby version
**
1
ruby -v