亲测解决Bundler HTTPError Could not fetch specs from

这个问题源于ruby的网站连接不上,解决方法是修改网页地址或者网络配置。

环境

win11 + ruby

问题原文

c 复制代码
Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from 
https://rubygems.org/ due to underlying error <IO::TimeoutError: Failed to open TCP connection to rubygems.org:443 (Blocking operation timed out!) (https://rubygems.org/specs.4.8.gz)>

解决方法

方法一

打开Gemfile,将https改成http,Open the Gemfile and change first line from this:

c 复制代码
source 'https://www.rubygems.org'

to this

python 复制代码
source 'http://www.rubygems.org'

remove the 's' from 'https'.

方法二

一般方法一就可以解决了,如果不行尝试换一个网络:比如手机wifi。

Change it to another network (mobile hotspot)

方法三

关闭ipv6的配置。

参考

https://stackoverflow.com/a/47392700/15329637

https://stackoverflow.com/questions/51201517/ruby-cant-connect-to-rubygems-org

相关推荐
该用户已不存在3 小时前
免费 SSL 证书缩短至 90 天,你的运维成本还能hold住吗
前端·后端·https
L***B5684 小时前
Nginx代理到https地址忽略证书验证配置
运维·nginx·https
伞啊伞6 小时前
nginx https ssl证书
nginx·https·ssl
大怪v7 小时前
【创世界01】头脑热一把,我要带你纯前端手搓虚拟世界💪!
javascript·css·html
DevUI团队8 小时前
解锁前端高阶调试:浏览器/IDE/Git技巧分享
前端·javascript·html
bloglin999998 小时前
gitlab内网配置https配置加载异常
网络协议·https·gitlab
dustcell.8 小时前
nginx的https搭建
运维·nginx·https
2501_915918419 小时前
iOS 手机抓包软件怎么选?HTTPS 调试、TCP 数据流分析与多工具组合的完整实践
android·ios·智能手机·小程序·https·uni-app·iphone
游戏开发爱好者810 小时前
iOS 应用上架的工程实践复盘,从构建交付到审核通过的全流程拆解
android·ios·小程序·https·uni-app·iphone·webview
l***466810 小时前
RabbitMQ 集群部署方案
分布式·rabbitmq·ruby