Credit to Grzegorz Juszczak
I am setting this up so I can SSH into any of the computers in my house to update them, transfer files, and even do remote development in VS Code (type on my laptop while the powerful desktop downstairs does all the compiling).
Because an SSH server is a convenient door for someone to brute force their way into I consider it VERY important that SSH keys are used, and that passwords are disabled.
Install OpenSSH (if needed)
sudo pacman -S openssh
Verify that your SSH service is inactive (should be by default) then start and enable it.
sudo systemctl status sshd.service sudo systemctl enable sshd.service sudo systemctl start sshd.service
Add your ssh key to the server
ssh-copy-id -i firstname.lastname@example.org
Disallow password authentication in
ssh email@example.com sudo nano /etc/ssh/sshd_config
#PasswordAuthentication yes to:
and save with
Ctrl + x,
Then restart your SSH service
systemctl restart sshd.service
Written by Alan Vardy. Let me know how I can make this better!