Hi,我是ruby新手一枚,在gem切换淘宝源的时候。我的命令如下:
gem sources --remove https://rubygems.org/
gem sources -a http://ruby.taobao.org/
提示我
这是什么问题?
PHP中文网2017-04-24 09:14:21
See RubyGems mirror
我们已经停止基于 HTTP 协议的镜像服务, 请在配置中使用 HTTPS* 协议代替
Q: gem install xxx 的时候遇到错误信息包含:“Error fetching data: Errno::ETIMEDOUT: Operation timed out - connect(2)”
A: 网络问题导致请求淘宝服务器被连接重置了,在遇到此类情况的时候,你可以尝试换一台机器或网络尝试安装,看是否还有同样的问题,以确定是淘宝镜像服务器的问题还是你的环境问题,如果你换了环境仍然有问题,请上 Ruby China 发帖求助。
阿神2017-04-24 09:14:21
I also encountered the problem above, and finally found the answer. Taobao’s gem source is no longer maintained. See the following link for the solution:
http://www.oschina.net/news/71749/taobao-gems-ruby-china
PHPz2017-04-24 09:14:21
When using multiple gem sources, you can consider using gsm-sources-manager for management switching.
伊谢尔伦2017-04-24 09:14:21
Regarding the problem of switching gem sources, I tried it after seeing the above reply and found it useful, but it didn’t go into too much detail. Here I will tell you my solution. I hope it can help people who see this post.