I have recently changed my GitHub username and when I try to push with Authentication > Use local SSH agent selected, GitKraken push fails with following error:
Push Failed
Configured SSH key is invalid.
Please confirm that it is properly associated with your git provider.
Unselecting the option reveals proper private/public key pair located at
~/.ssh/id_rsa
~/.ssh/id_rsa.pub
and allows the push to be done.
I can also push from inside Eclipse, and via command line without error. The URL of the repository point to my new username.
So far I have checked several things:
ssh -T github.com
gives permission denied
Fingerprint of id_rsa.pub matches to a key existing in Github account.
The following command suggests that ssh tool tries rsa private key, but is rejected:
$ ssh -vT github.com
debug1: Offering RSA public key: /home/<user>/.ssh/id_rsa
debug1: Authentications that can continue: publickey
debug1: Trying private key: /home/<user>/.ssh/id_dsa
debug1: Trying private key: /home/<user>/.ssh/id_ecdsa
debug1: Trying private key: /home/<user>/.ssh/id_ed25519
debug1: No more authentication methods to try.
Permission denied (publickey).
What is causing ssh -vT to fail in this case, and why doesn't it prevent git push/pull but fails when GitKraken tries pushing?
GitHub SSH configurationConfirm that your public key has been configured correctly by checking the SSH and GPG link in your account settings. If no keys are listed, add your public key and try to connect to GitHub over SSH again. The error should go away.
On GitHub the term they use to refer to a repository SSH key is a Deploy key. Visit the Settings page for the repository, and then click on Deploy keys. Click on Add deploy key and enter a name for the repository SSH key as the Title field, and copy the contents of the public key file into the Key field.
For people who will come here in the future, my case was that pull/push working on vsc but gitkraken was giving me the message : no auth sock variable. I went into file > preferences > SSH > unmarked use local SSH agent then it automatically found my id_rsa, ida_rsa.pub (you can browse and locate them manually if needed) and now everything working fine.
OS: Arch, gitkraken version: 7.7.2
For me this was caused by an upgrade to OSX Sierra. I had to execute
ssh-add -k ~/.ssh/id_rsa
(you might have to replace that with the path of the key you are using). The command adds the ssh key to the git agent. For more information see the GitHub Help Page about adding SSH Keys. You might have to add the command to some sort of setup file which is run at boot, because it seems like the ssh agent doesn't remember the key (at least for me).
What helped me resolve the issue was to go to GitKraken preferences and connect both Bitbucket and Github and authorize them.
After that tick the box in "general" that says use local ssh agent. (might be
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With