Could not verify the SSL certificate for https://rubygems.org/
git, github, ruby, ruby-on-rails, ssl
Solution
I had this problem on Mac OS X Yosemite with ruby 2.3.1. I fixed the problem by downloading http://curl.haxx.se/ca/cacert.pem to `/usr/local/etc/openssl/`
and adding this line `export SSL_CERT_FILE=/usr/local/etc/openssl/cacert.pem` to `.bash_profile`
Credit to Can't run Ruby 2.2.3 with RVM on OSX but it was hard to google the right answer, so added to this page.
Problem
I'm getting this error when I run `bundle install`: ``` Could not verify the SSL certificate for https://rubygems.org/. There is a chance you are experiencing a man-in-the-middle attack, but most likely your system doesn't have the CA certificates needed for verification. For information about OpenSSL certificates, see bit.ly/ruby-ssl. To connect without using SSL, edit your Gemfile sources and change 'https' to 'http'. ``` However, it is only happening to one of my projects, and seems to be happening to only me. Also, I can get around it by running `bundle update`, where I don't get that error, and I can get up a running after that. Is there something that isn't tracked in the project (that is only on my machine) that I have misconfigured?