I want to be able to:
I do not see how else I can use ssh-key pair on the root account and still get the benefit of being able to login via Digital Oceans virtual Console that they give in their browser.
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
@nyeates1
If you have setup a ssh key pair on Digital Ocean and used it when creating the droplet, then your SSH is configured to only accept public key authentication for your root user and no password is assigned to root, to set it up login via ssh as root and issue this command
passwd
to change password.If you did not use a key pair when creating the droplet, then a password will be generated for root account and you change it when logging in for the first time, here you need to do the following to disable using passwords when connecting with SSH:
ssh-keygen
ssh-copy-id root@<droplet_ip>
.PasswordAuthentication no
in/etc/ssh/sshd_config
.PubkeyAuthentication yes
sudo service ssh restart
Now you can access your droplet over SSH with your public key as root and login to KVM console as root with your password.
Hope this helps.