it:ad:bitbucket:howto:register_an_ssh_key

IT:AD:BitBucket:HowTo:Register an SSH Key

Mercurial from the CI/ was easy enough. Git was harder.

The issue is that with HTTPS for every command one had to upload the username/password. Not very secure even over HTTPS.

The solution is to to create an IT:AD:SSH key pair, and upload the public key to BitBucket.

If BitBucket is recommending using IT:AD:SSH, why is GitHub/ recommending the use of HTTPS/? Interesting reasoning: http://stackoverflow.com/questions/11041729/why-does-github-recommend-https-over-ssh

  • A public/private identity key can only be used with one BitBucket/ account
  • You can have multiple identities (ie private/public keys), each one associated to different BitBucket/ accounts.
  • Using SSH means you'll have to change Urls. Your Repository will now have to be re-cloned from:

    ssh://git@bitbucket.org/accountname/reponame.git
    ssh://git@bitbucket.org/xact/gittest.git

instead of

    https://accountname@bitbucket.org/accountname/reponame.git
    https://skysigal@bitbucket.org/xact/gittest.git

Note:Note that the ssh option has mechanism to pass the user name...

After creating a public/private key:

You should see something similar to:

Important:The response tells you which account can log on with that key -- in this case, `xact`.Only that account can use this key.
  • /home/skysigal/public_html/data/pages/it/ad/bitbucket/howto/register_an_ssh_key.txt
  • Last modified: 2023/11/04 03:38
  • by 127.0.0.1