解决gem update --system的Gem::RemoteFetcher::FetchError错误

先前解决过没记录,新做环境又再解决一次,现记录之,感谢Stack Overflow网站。

https://gist.github.com/fnichol/867550

不好使,怀疑是证书文件损坏,使用原先下载的证书代替,结果去连接亚马逊的服务器,然后又失败,最终怀疑是伟大的GFW在起作用,索性换了淘宝的镜像。

gem source查看列表;

gem source -a http://ruby.taobao.org 加入淘宝的源,居然没用https,也就不存在这个问题了;

gem source -r https://rubygems.org/ 干掉缺省的源;

gem update --system 它工作了!

你可能感兴趣的:(解决gem update --system的Gem::RemoteFetcher::FetchError错误)