Import SSH keys for remote server
I have an Ubuntu 15.10 X64 and I am working on a project for which I am trying out GIT. I have created a repo on one of our remote servers, which is a Debian server, and the repo is accessible via SSH from command line as well as from Intellij. If you need any info, please let me know
I am trying to access it via a GIT-UI tool called GitGraken. It is looking for ssh keys for our remote server. How can I get those keys and add it for my user on the system so I can keep an eye on the repository. Any help would be nice.
3 Answers
You can create a ssh keypair in the terminal with the command: ssh-keygen. Then you have to add the public key(.pub).
see man ssh-keygen for more options
Use ssh-copy-id
If your local machine has the ssh-copy-id script installed, you can use it to install your public key to any user that you have login credentials for.
Run the ssh-copy-id script by specifying the user and IP address of the server that you want to install the key on, like this:
ssh-copy-id demo@SERVER_IP_ADDRESS 1 Finally, this link from debian helped. I created a key first with following command on my local machine :
ssh-keygen -t rsaThen I copied contents of the public key(/home/username/.ssh/id_rsa.pub) into authorized keys on the server. After that I was able to login without password and solve the problem.
10