git push heroku master出现Operation/Connecting timed out错误

 

转载自ruby-china http://ruby-china.org/topics/10813

 

git push heroku master出现Operation/Connecting timed out错误。

用“ssh -v [email protected]”检查后发现原因在于fuck GFW!!!以下节点全部不可用:
174.129.23.118
174.129.22.35
50.16.233.102
50.19.85.154
50.19.85.132
50.16.215.67
50.19.85.156
184.73.165.65
50.16.215.104
107.21.106.77
107.21.105.64
107.22.234.17

仅有以下节点可用:
107.21.95.3

故手动配置vi ~/.ssh/config:
Host heroku.com
User freemember007
Hostname 107.21.95.3 #关键设置,替代proxy.heroku.com,直接走IP。
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
port 22

 

ubutu下没有.ssh/config文件,这样解决:

-----------------------------------------------------------------------------------

项目跟目录下:去git设置文件里(.git/config),把remote分支里的
[email protected]
改成
[email protected]即可

你可能感兴趣的:(heroku,time out)