创建我的rails项目后,将其推入GIT仓库,无法将其推送到Heroku。 当我运行命令时:
git push heroku master
我收到此错误:
ssh: connect to host heroku.com port 22: Bad file number
fatal: The remote end hung up unexpectedly
不在防火墙,代理或VPN后面...... 我跑了
heroku status
它工作正常。
我甚至确保ssh与Git一起正常工作。并运行
ssh -vT git@github.com
并且运行成功
我跑
telnet heroku.com 22
它失败了
connecting to heroku.com .. could not open connection to the host, on port 22:Connect failed
同时运行并失败
ssh git@heroku.com
ssh: connect to host heroku.com port 22: bad file number
答案 0 :(得分:1)
可怕的坏文件编号。这是git的PC LOAD LETTER。这是不可思议的,但几乎总是一把坏钥匙。尝试更新heroku中的密钥,并确保在尝试连接时显示正确的密钥。