Git asks for password when pushing to bitbucket or github

First check that you’ve properly set up a ~/.ssh/config file with following parameters:

Identityfile /root/.ssh/id_rsa
User myusername

Also check that you’ve clone the repo using the
git clone [email protected]:username

rather than the

git clone https:[email protected]/username/securessh.git

If you use HTTPS it always asks for a password.

You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.