I set up hostname aliases in .ssh/config
, which works great:
Host my-web
HostName 515.346.96.21
So I can do this:
ssh my-web
But in a browser, I still need to type in "http://515.346.96.21
". It would be great to be able to do "http://my-web
".
Short of using a Dynamic DNS, or writing a script to synchronise changes with /etc/hosts
, is there a way to use the aliases in SSH more widely? I create and destroy VMs with different IPs pretty often, so am constantly updating ~/.ssh/config
.