GitHub 文件加速方法分享
有些时候我们访问GitHub项目下载或者静态文件时,往往遇到下载速度超慢,总是超时导致下载失败。那么这么提高GitHub问价下载速度呢?
在网络上搜集到了一些可用的代理站,都是通过 Cloudflare Workers 对 github release 、archive 以及项目文件进行加速,部署无需服务器且自带CDN。开网项目:gh-proxy-GitHub
在网址后直接添加GitHub网址即可加速:公益站,避免大量请求。
https://gh.cyp0633.icu/ http://gh.not.icu/ http://gh.zhaojun.im/ https://get.geshandaniu.me/ http://github.sres.life/ https://github.cooluc.com/ https://gfw.lomorage.com/ https://gh.chjina.com/ http://gh.api.99988866.xyz/
GitHub raw 加速
什么是:raw.githubusercontent.com ?
是github用来存储用户上传文件(不是项目仓库的文件,而是issue里的图片之类的)的服务地址。放在亚马逊s3上。是github 的素材服务器 (assets server), 避免跟主服务抢占负载。
GitHub raw 域名并非 http://github.com 而是 http://raw.githubusercontent.com,上方的 GitHub 加速如果不能加速这个域名,那么可以使用 Static CDN 提供的反代服务。
将 http://raw.githubusercontent.com 替换为 http://raw.staticdn.net 即可,或者直接访问http://raw.githubusercontents.com。
当然也可以通过上面的网站进行加速。
使用方法:
打开一个项目,点击raw,就会跳转到指定界面:https://raw.githubusercontent.com/hunshcn/gh-proxy/master/Dockerfile,提示网络连接错误。
链接1:https://gh.cyp0633.icu/https://raw.githubusercontent.com/hunshcn/gh-proxy/master/Dockerfile
链接2:https://raw.githubusercontents.com/hunshcn/gh-proxy/master/Dockerfile