Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Suddenly can't push to heroku: "unable to negotiate key exchange method"

"git push heroku" is suddenly failing. (I installed Node.js and I think it may have upgraded some things and broke this somehow.)

I've read all the similar posts; it's not telling me which exchange was 'offered', and everything looks like it matches, but the call fails and I'm at a loss.
I did heroku auth:login successfully.

ssh [email protected] -v gives me the following:

OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /Users/jeff/.ssh/config
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for * <This line is 'Host *'>
debug1: Connecting to heroku.com [50.19.85.156] port 22.
debug1: Connection established.
debug1: identity file /Users/jeff/.ssh/id_rsa type 1
debug1: identity file /Users/jeff/.ssh/id_rsa-cert type -1
debug1: identity file /Users/jeff/.ssh/id_dsa type -1
debug1: identity file /Users/jeff/.ssh/id_dsa-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.2
debug1: Remote protocol version 2.0, remote software version endosome
debug1: no match: endosome
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-ctr [email protected] none
debug1: kex: client->server aes128-ctr [email protected] none
Unable to negotiate a key exchange method
like image 629
user3407688 Avatar asked Oct 19 '17 15:10

user3407688


People also ask

How do I force push to Heroku?

To deploy your app to Heroku, use the git push command to push the code from your local repository's main branch to your heroku remote. For example: $ git push heroku main Initializing repository, done.

What does git push heroku master do?

git push heroku master - Solace. EDA Platform Build and manage an event mesh that integrates assets across your enterprise in real-time. Event Broker Stream information between applications and devices across clouds, datacenters and the Internet of Things.


1 Answers

I encountered same problem this morning.

I can avoid this problem, with change git remote url as below.

from: [email protected]:app-name.git

to: https://git.heroku.com/app-name.git

you can use command below

git remote rm heroku git remote add heroku https://git.heroku.com/app-name.git

like image 99
daik Avatar answered Sep 30 '22 05:09

daik