gem install bundle ERROR: Cou-6ren">
gpt4 book ai didi

ruby - 在 Windows 上安装 Ruby gems 时出现 "certificate verify failed"错误

转载 作者:可可西里 更新时间:2023-11-01 12:24:56 25 4
gpt4 key购买 nike

我正在使用运行 8.1 并使用 Ruby Installer 2.1.5 的 Windows PC。

安装 gem 时出现错误:

C:\> gem install bundle
ERROR: Could not find a valid gem 'bundle' (>= 0), here is why:
Unable to download data from https://rubygems.org/ - SSL_connect retur
ned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (
https://api.rubygems.org/latest_specs.4.8.gz)

希望有好的解决办法

最佳答案

我也遇到过这个问题。但使用旧版本并不是正确的解决方案。

这里有两个解决方案可以帮助修复这个证书错误

<强>1。使用 http 而不是 https 将允许您安装 gem 而不会出现该错误

gem install bundler -r --source http://rubygems.org/

<强>2。根据以下链接中提供的解决方案更新证书

https://gist.github.com/luislavena/f064211759ee0f806c88

关于ruby - 在 Windows 上安装 Ruby gems 时出现 "certificate verify failed"错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27380301/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com