github登录调试以及应用代理

github登录不了,调试如下:

$ GIT_TRACE=1 git fetch origin

输出:

如上所示,卡在ssh这里。试着手工执行上面的ssh命令,并加上-v选项:

$ ssh -v git@github.com 'git-upload-pack '\''resteasy/Resteasy.git'\'''

输出如下:

创建config文件:

$ ls ~/.ssh/config
/Users/weli/.ssh/config

内容如下:

安装corkscrew

$ brew install corkscrew

安装好以后,加代理执行ssh命令:

$ ssh -o ProxyCommand="corkscrew squid.corp.redhat.com 3128 %h %p" -v git@github.com 'git-upload-pack '\''resteasy/Resteasy.git'\'''

能够看到已经可以连接:

在上面输入yes后,卡在65535

不管上面的问题,直接在config里添加调试的proxy命令:

重新尝试执行git命令:

$ GIT_TRACE=1 git fetch origin

运行过程和结果如下:

My Github Page: https://github.com/liweinan

Powered by Jekyll and Theme by solid

If you have any question want to ask or find bugs regarding with my blog posts, please report it here:
https://github.com/liweinan/liweinan.github.io/issues