如何解决bundle install rake错误和Gem :: RemoteFetcher :: FetchError [英] How to resolve bundle install rake error and Gem::RemoteFetcher::FetchError

查看:293
本文介绍了如何解决bundle install rake错误和Gem :: RemoteFetcher :: FetchError的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

  Gem :: RemoteFetcher :: FetchError:SSL_connect返回= 1 errno = 0 state = SSLv3读取服务器证书B:证书验证失败(https://rubygems.org/gems/rake-10.4.2.gem)
安装rake(10.4.2)时发生错误,并且Bundler无法继续。
确保在捆绑之前`gem install rake -v '10.4.2'`成功。

当我运行 gem install rake

 错误:找不到有效的gem'bundle'(> = 0),原因如下:
无法从https://rubygems.org/下载数据 - SSL_connect返回= 1 errno = 0状态= SSLv3读取服务器证书B:证书验证失败

当我运行捆绑时,我得到:

  /usr/local/rvm/gems/ruby-2.1.2@global/bin/bundle 

这个错误阻止了我在部署之前在localhost:3000上进行开发工作。



有谁知道如何解决这个问题? 升级升级到最新版本的Ruby,或者至少比你拥有的版本更新。我正在使用2.0.0-p247并收到相同的错误。当我升级到2.2.5(这是写作时最老的支持版本),那么一切正常。



我还必须运行升级红宝石后,gem install bundler 。最后,我使用rbenv并安装了ruby,并且安装了 rbenv install 2.2.5 然后运行 rbenv local 2.2.5

When I run bundle install on ruby 2.1.2 I get:

Gem::RemoteFetcher::FetchError: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://rubygems.org/gems/rake-10.4.2.gem)
An error occurred while installing rake (10.4.2), and Bundler cannot continue.
Make sure that `gem install rake -v '10.4.2'` succeeds before bundling.

When I run gem install rake I get:

ERROR:  Could not find a valid gem 'bundle' (>= 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

When I run which bundle I get:

/usr/local/rvm/gems/ruby-2.1.2@global/bin/bundle

This error is preventing me from doing development work on localhost:3000 before deploying.

Does anyone know how to resolve this issue?

解决方案

Upgrade to the latest version of Ruby or at least a newer version than the one you have. I was using 2.0.0-p247 and received the same error. When I upgraded to 2.2.5 (which is the oldest supported version at the time of this writing) then everything worked.

I also had to run gem install bundler after upgrading ruby. Last, I'm using rbenv and installed ruby with rbenv install 2.2.5 then ran rbenv local 2.2.5.

这篇关于如何解决bundle install rake错误和Gem :: RemoteFetcher :: FetchError的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆