ssh-agent

ssh-add -l    # to list the agent's keys, 
ssh-add -D   # to clean out all keys.

SO

How to Setup Multiple Ssh Keys for Multiple Github/Bitbucket accounts.

~/.ssh/config can contains rules to use different keys depending on the host contacted.

Host github.com
  HostName github.com
  IdentityFile ~/.ssh/id_rsa_github

Host gitlab.com
  HostName gitlab.com
  IdentityFile ~/.ssh/id_rsa_gitlab
Written on August 19, 2018, Last update on October 16, 2020
ssh