How to Login Automatically With SSH
Auto Login With SSH
Let’s say there is a server and your local machine, assuming you can login to the server using some kind of credentials.
First off, you should generate a new local public key on your local machine.
Chdir to the current user’s root directory.
1cd
2ssh-keygen
If you see a prompt message of existing file, just overwrite it, give yes to every prompt otherwise.
You can copy the generated public key to the server by this only one command 🙂
1ssh-copy-id username@hostname
Use your existing credentials for prompts.
If you see a message telling you to login to the server again, you are done. Pretty simple saving much time. 😎