You can install it with default yum install -y ruby ruby-devel rubygems
Other way is to compile it by yourself
Ruby
wget http://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.7-p302.tar.gz
tar -zxvf ruby-1.8.7-p302.tar.gz
cd ruby-1.8.7-p302
./configure --with-openssl-dir=/usr/lib/openssl
make
make install
Rubygems
wget http://production.cf.rubygems.org/rubygems/rubygems-1.3.7.tgz
tar -zxvf rubygems-1.3.7.tgz
cd rubygems-1.3.7
ruby setup.rb config
ruby setup.rb setup
ruby setup.rb install
In what capacity are you trying to use Ruby? If you don't need it systemwide, Have you considered using RVM locally so you can install ruby into your local directory? Additionally you can install rvm systemwide. It takes some doing, but it's a better solution that tossing files across your server.
You can install it with default
yum install -y ruby ruby-devel rubygems
Other way is to compile it by yourself
Ruby
Rubygems
Check if installed
In what capacity are you trying to use Ruby? If you don't need it systemwide, Have you considered using RVM locally so you can install ruby into your local directory? Additionally you can install rvm systemwide. It takes some doing, but it's a better solution that tossing files across your server.
Installing RVM
I'd test it out first in your local directory until you get comfortable with it.