0

The past few days I keep getting this error whenever I try to install a gem:

ERROR:  Could not find a valid gem 'sass' (>= 0), here is why:
          Unable to download data from https://rubygems.org/ - Errno::EACCES: Pe
rmission denied - connect(2) for "rubygems.org" port 443 (https://rubygems.org/l
atest_specs.4.8.gz)

I have tried this:

gem install rails --source http://rubygems.org

Have updated my gem version (now 2.2.3) and still nothing. I'm at a complete loss...Where am I going wrong?

  • That looks like a severely strict local security setting. – tadman Jun 29 '15 at 18:55
  • Hmm, I have tried with firewall disabled, but I'll play around with that a bit more and see if I've missed something. – user3163539 Jun 29 '15 at 18:58
  • It sounds like, for whatever reason, your Ruby process is completely unable to access port 443. You may need to authorize it somehow. This is an application level outbound firewall setting of some sort. – tadman Jun 29 '15 at 19:02
  • 1
    3 days of confusion and it was all Nortons fault. *sigh*. Thank you for your help! – user3163539 Jun 29 '15 at 19:02

1 Answers1

0

Generally this is the result of a super strict application firewall setting. Sometimes applications are restricted in the sorts of external connections they can make and this can interfere with the Ruby Gem downloading process.

Make sure your Ruby process has access to port 443 when making external connections.

tadman
  • 208,517
  • 23
  • 234
  • 262