Scale up as you grow — whether you're running one virtual machine or ten thousand.

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.

This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
If you don’t have ssh-copy-id you can use the following command: cat ~/.ssh/id_rsa.pub | ssh user@machine “cat >> ~/.ssh/authorized_keys”
Dear Digital Ocean. You guys make the best tutorials. Thank you so much.
Great article, but what if your client is a Windows box and you’ve generated your public key with Puttygen, then need to transfer it to your VPS? Is there any way to copy-paste the public key, for example using nano? I’d rather not create a completely new server using the ‘Addendum’ method.
If you are copying the key over to a server you can certainly SSH and in and use nano/vi or any other editor and copy and paste it in. Just make sure that the formatting is preserved and no new line characters are added.
If I misunderstood the question let me know.
Wow, thanks for the quick reply on a Sunday night :-) I tried that and must have made a mistake as I couldn’t get it to work. I had created a way too large DSA key anyway. Since I’m trying to learn anyway, I’ve decided to recreate a droplet from scratch and get this down before I proceed. I’ll try integrating the SSH key through your ‘addendum’ method next time. I’m assuming I can just copy-paste the entire key, or do I have to omit lines like '---- BEGIN SSH2 PUBLIC KEY ---- Comment: “rsa-key-20130121”?
I think you may be looking at the wrong file possibly, because when the key is created the public one that you should be sharing doesn’t have any comments, so you can copy and paste it directly.
Please make sure that you are copying and pasting from the file that ends in “.pub”
I’m pretty sure I had the correct file, but to make sure I’ve put an exact copy/paste on Pastebin: http://pastebin.com/Hzi30uMM Apparently puttygen adds lines Linux doesn’t?
On Linux you would get : ssh-dss AAAAB3NzaC1yc2EAAAABJQAAAQEAgj… user@host
That should all be on one-line, the ssh-dss portion is because the key was created with dsa instead of rsa.
But thats what it should look like and you should paste it in on one line.
Right. Just to make sure I’ve got everything down correctly: if my username were ocean and my IP were 185.14.185.149, and my key were in ssh2-rsa the correct format would be:
ssh-rsa [key with all line breaks removed] ocean@185.14.185.149
Which I can then add to the Digital Ocean control panel and will be integrated in any future droplets I create.
Correct? Thanks!