how to create authorized keys

I’m following along with this tutorial about how to use git to deploy to a remote server with a simple command like ‘git push web.’ The article has the following paragraph

“I assume that the web site will live on a server to which you have ssh access, and that things are set up so that you can ssh to it without having to type a password (i.e., that your public key is in ~/.ssh/authorized_keys and you are running ssh-agent locally).”

In the .ssh directory on my local machine, I have

“id_rsa key_backup known_hosts”

i.e. there is no ‘authorized_keys’

Can anyone explain how I might create authorized keys for this to work? thanks in advance

Submit an answer

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!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Run: ssh-copy-id user@ip - this command will copy your public key into ~/.ssh/authorized_keys <br> <br>Make sure it works by running: ssh user@ip <br>If you are not prompted for a password and successfully log in, it works.

Check out: <br> <br>1.) <a href=“”>How to Create SSH Keys with PuTTY to Connect to a VPS | DigitalOcean</a>; <br> <br>2.) <a href=“”>How to Set Up SSH Keys | DigitalOcean</a>; <br> <br>3.) <a href=“”>How to Install Git on Ubuntu 12.04 | DigitalOcean</a>; <br> <br>4.) <a href=“”>How to Use Git Effectively | DigitalOcean</a>; <br> <br>5.) <a href=“”>How to Use Git Branches | DigitalOcean</a>