Hacker News new | ask | show | jobs
by codeape 2731 days ago
Is the first "Using a Configuration File" example a bit misleading? The example is:

... Host remoteserver HostName remoteserver.thematrix.io User neo Port 2112 IdentityFile /home/test/.ssh/remoteserver.pub

IdentityFile typically (always?) specifies a file with a private key, right?

2 comments

Unless you're using something like a smart card as identity with gpg-agent, then you won't have a private key file. Because of that, you can specify a public key file to identify this private key.
Also it's suggested to use ~/.ssh/key to specify a key in your home folder to be a portable config and don't really need to show others what your user name is if it gets shared.