I’m really hoping that someone can provide me with some enlightenment.
I have a lot of ssh keys. 6 by today’s count. On my desktop I have my ssh configured with
IdentitiesOnly yes and an
IdentityFile for each host. This works great.
I then forward my agent to my dev VM. I can see the keys with
ssh-add -l. So far so good. If I then ssh into a host, I can see it trying every key from the agent in sequence, which is sometimes going to fail with too many keys tried. However, if I try
IdentitiesOnly yes in my dev VM config, it doesn’t offer any keys, if I add
IdentityFile it doesn’t work because I don’t have those key files on my VM.
So what’s the solution? What I want is to specify identities by their identifier in the agent, e.g. danni@github, however I can’t see config to do that. Anyone got a nifty solution?