Register SSH Key To DigitalOcean

I just added new ssh key from my laptop into my digitalocean settings, to ensure next login in my laptop, I don’t need to type my password again and again. But after adding my ssh key and trying to login to my VPS, the ssh still asked me for a password.

Here is how I fix this following the documentation. I assuming that you guys know how to generate new ssh key. So below is next step after generating new ssh key.

$ cat ~/.ssh/id_rsa.pub | ssh root@[your.ip.address.here] "cat >> ~/.ssh/authorized_keys"

After run single command above, I don’t need to type password once logging in to my VPS.

Reference: https://www.digitalocean.com/community/tutorials/how-to-use-ssh-keys-with-digitalocean-droplets

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s