Add Your Public SSH Key To Your Server In One Command You will need to create .ssh/authorized_keys if it is not yet on your server. cat ~/.ssh/id_rsa.pub | ssh user@hostname 'cat >> .ssh/authorized_keys' Generating Your Own Public Key