2016-10-11 60 views
4

我不知道这个错误在尝试运行时意味着什么gem update --system;无法从rubygems下载数据

{9:29}[2.2.3]~ ➭ gem update --system 
ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) 
SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://api.rubygems.org/specs.4.8.gz) 

尝试时我也会遇到类似的错误;

{9:30}[2.2.3]~ ➭ gem install tunnelss 
ERROR: Could not find a valid gem 'tunnelss' (>= 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) 

仅供参考 - 我可以访问浏览器https://api.rubygems.org/specs.4.8.gz,它会开始下载所以这不是问题。

不知道该做什么。任何人都可以建议吗?

回答

6

这是一个已知问题,请参阅https://gist.github.com/luislavena/f064211759ee0f806c88和/或https://gist.github.com/fnichol/867550来解决它。

昨天当我在Windows上安装Ruby时,我偶然发现了相同的问题。所以,亲自,这https://superdevresources.com/ssl-error-ruby-gems-windows/为我工作。另一个指南提到了一个不存在的URL到cacert.pem

+2

试试我的解决方案在这里http://stackoverflow.com/a/40299098/80357 –

+0

@WilliamNotowidagdo尝试你的解决方案,导致与原始问题尝试相同的SSL错误解决... – knocte

+0

实际上似乎是一个警告,而不是一个错误 – knocte