No Ssh Config File

Posted on  by 



Make SSH easy by adding entries to your local SSH config file. From this file we can set useful defaults to make logging into remote servers as easy as ssh myserver.In the previous video, we used this long command to login with a newly created SSH key:

Make SSH easy by adding entries to your local SSH config file. From this file we can set useful defaults to make logging into remote servers as easy as `ssh myserver`. Create the SSH folder to store the SSH config files: mkdir -p /.ssh. Change permission to the folder to 0700 (read, write, and execute only for owner): chmod 0700 /.ssh. Next, we need to create the SSH config file, and set the permissions to 0700: touch /.ssh/config chmod 0700 /.ssh/config. Now that our files are created, we need to connect.

Locally on my Mac, I can create/edit an ssh config file:

Add the following to mirror our long command:

No Ssh Config File Extension

Save and exit that file, and try to login in our simpler way:

Ssh Without Config File

No ssh config file extension

Ssh Config File Location

We can use this with any SSH-based tool:

See the man page of ssh to check out all the options you can use in the config file.





Coments are closed