安装ruby报错:Failed to connect to raw.githubusercontent.com port 443: Connection refused

使用命令
curl -L https://get.rvm.io | bash -s stable
在mac安装ruby报错:Failed to connect to raw.githubusercontent.com port 443: Connection refused

原因是国内dns被污染,无法解析正确的ip地址,在host文件加入:

#因为dns被污染导致ruby无法安装的解决方案
199.232.28.133 raw.githubusercontent.com

(修改host推荐使用switchHost)

站点的ip地址有可能变更,通过:https://githubusercontent.com.ipaddress.com/raw.githubusercontent.com 可查询真实ip地址

上一篇 Flutter当前路由属性详解
下一篇 在markdown中插入项目目录结构