We need to create an alternative certificate for the second account (pk stored in id_rsa.myotheridentity).
WARNING: when generating the new credentials take care not to overwrite any id_rsa and id_rsa.pub files you may have in ~/.ssh
Edit ssh config in ~/.ssh/config
. Create it if not exists.
Host gitlabmyproject
Hostname gitlab.com
IdentityFile ~/.ssh/id_rsa.myotheridentity
IdentitiesOnly yes
Clone the repo:
git clone git@gitlabmyproject:myrepo.git
Done!