Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VSCode SSH remote friendly host name

I have this .config file for SSH hosts:

Host 10.32.1.43
  HostName 10.32.1.43
  User root
  ForwardAgent yes
Host 10.32.0.39
  HostName 10.32.0.39
  User administrator
  ForwardAgent yes

Can I give more friendly names to my machines, instead of remembering which of them is the Ubuntu machine, and which is the CentOS?

like image 457
baruchiro Avatar asked Oct 19 '25 03:10

baruchiro


1 Answers

If you change the name after "Host", it changes the name displayed in VSCode and normal ssh commands

Host {machine_name}
   HostName {your_ip}
   User {your_username}

Using this example config file, you can do: ssh {machine_name}

like image 90
conner wallace Avatar answered Oct 22 '25 04:10

conner wallace



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!