Github 图片或头像无法加载解决方法

2020-07-12  本文已影响0人  mocobk

Github 有时出现图片或头像加载不出来的问题,影响阅读,如下图所示,查找原因是因为 DNS 解析有问题


image.png

解决方法

在 hosts 文件中添加以下域名对应的解析地址

# GitHub Start
140.82.114.4 gist.github.com
185.199.108.153 assets-cdn.github.com
151.101.64.133 raw.githubusercontent.com
151.101.108.133 gist.githubusercontent.com
151.101.108.133 cloud.githubusercontent.com
151.101.108.133 camo.githubusercontent.com
151.101.108.133 avatars0.githubusercontent.com
151.101.108.133 avatars1.githubusercontent.com
151.101.108.133 avatars2.githubusercontent.com
151.101.108.133 avatars3.githubusercontent.com
151.101.108.133 avatars4.githubusercontent.com
151.101.108.133 avatars5.githubusercontent.com
151.101.108.133 avatars6.githubusercontent.com
151.101.108.133 avatars7.githubusercontent.com
151.101.108.133 avatars8.githubusercontent.com 
# GitHub End

mac / linux: /etc/hosts 若没有可以创建一个
windows: c:\windows\system32\drivers\etc\hosts windows 一般都会有

上一篇下一篇

猜你喜欢

热点阅读