in .ssh/config file
Scenario is that I have two public ips now (dynamic), one is connect to aws and one is connect to rackspace
Both require different pem keys to connect. But I want to use ssh config file to save my time
Host <ip1> User root Port 22 HostName %h IdentityFile ~/.ssh/aws.pem Host <ip2> User root Port 22 HostName %h IdentityFile ~/.ssh/rackspace.pem
From this setting, i cannot distinguish which pem file to be use. I want to make use of the Host as part of parameter to specify which server to connect to e.g. ssh aws-ip1 ssh rack-ip2
then the config file can distinguish which pem file to use
Anyone know how to do this?