Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
613 views
in Technique[技术] by (71.8m points)

ruby on rails - Windows 7 64-bit: Could not find a valid gem 'compass' (>= 0), here is why: Unable to download data from https://rubygems.org/

I cannot install compass. I want to install compass on my project so when I try to update, I get this:

c:wampwwwdanjasnowski.com>gem install compass ERROR: Could not find a valid gem 'compass' (>= 0), here is why: Unable to download data from https://rubygems.org/ - SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://api.rubygems.org/specs.4.8.gz)

Also.. my current version.

c:wampwwwdanjasnowski.com>gem --version

2.4.1

and

irb(main):001:0> RUBY_VERSION

=> "2.0.0"

irb(main):002:0> RUBY_RELEASE_DATE

=> "2014-05-08"

irb(main):003:0> RUBY_PLATFORM

=> "x64-mingw32"

irb(main):004:0> RUBY_PATCHLEVEL

=> 481

irb(main):005:0>

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Try upgrading your SSL certificates.

  1. Download http://curl.haxx.se/ca/cacert.pem

  2. Save this file anywhere you want, such as:

    C:cacert.pem
    
  3. On the command line, tell Ruby where to find the cert file, such as:

    set SSL_CERT_FILE=C:cacert.pem
    
  4. Try again.

    gem install compass
    
  5. If it works, you can make the cert file permanent by adding it in your control panel.

Credit and more info: https://gist.github.com/fnichol/867550


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...