ssh-keygen -t rsa -b 4096 -C "[email protected]"
ssh-add id_rsa_mjrulesamrat
Create config file and add multiple hosts to accomodate different accounts of github, bitbucket or gitlab.
vim ~/.ssh/config
Host github.com
HostName github.com
IdentityFile ~/.ssh/id_rsa
Host mjrulesamrat.github.com
HostName github.com
IdentityFile ~/.ssh/id_rsa_mjrulesamrat
Other examples of different accounts:
-
mjrulesamrat.gitlab.com
-
mjrulesamrat.bitbucket.org
Add id_rsa_mjrulesamrat.pub
to github account ssh keys
cat ~/.ssh/id_rsa_mjrulesamrat.pub
git clone [email protected]:mjrulesamrat/docker-commands.git
ssh
url from the git repositoryThis should work.
Currently this is working for me.
cc @mjrulesamrat