After installing the Ruby installer you might need to install some gems. For example, if you are developing with RedHat OpenShift you want to install ‘rhc’ gem to access remote files on OpenShift. To install ‘rhc’ you would run the following command.
>gem install rhc
But you might get the following error, especially on a Windows machine.
>gem install rhc ERROR: Could not find a valid gem 'rhc' (>= 0), here is why: Unable to download data from https://rubygems.org/ - SSL_connect retur ned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed ( https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/rhc-1.15.6.gemspec.rz) ERROR: Possible alternatives: rhc
The problem is due to running over a secure (https) connection to rubygems.org. Look at the help for “gem sources –h”, remove the https version and add http://rubygems.org
Run the following commands to do this.
>gem sources --remove https://rubygems.org/ >gem sources --add http://rubygems.org/
And now you can easily install any gem.