Forums

Resolved
0 votes
We need a developers section in the forums!!!

I have problems with the developers documentation. See this part:

SSH Keys

I have created a public and a private key with putty key generator but it's not clear to where to put these keys. If I want to clone the "app-date"


[MvL@server apps]$ git clone git@gitlab.com:MvL72/app-date.git
Cloning into 'app-date'...
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.


I receive this error due no key..

btw I'm using Windows.
Sunday, October 21 2018, 08:34 AM
Share this post:
Responses (5)
  • Accepted Answer

    Sunday, October 21 2018, 06:45 PM - #Permalink
    Resolved
    0 votes
    I generate a new key for the user MvL and it's working now! :)
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, October 21 2018, 06:32 PM - #Permalink
    Resolved
    0 votes
    So my assumption then was correct. Thank you Nick.
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, October 21 2018, 01:24 PM - #Permalink
    Resolved
    0 votes
    Yes, that is for the root user. For normal users it goes in a similar place under their home folder.
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, October 21 2018, 12:10 PM - #Permalink
    Resolved
    0 votes
    Thanks for pointing me in the right direction.

    I'm now testing with ssh-keygen. The location you point to is for the root user if I'm correct?

    I'm using app-date just for trying. No plans to change it, and probably I even can't due my limited knowledge. :)
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, October 21 2018, 11:30 AM - #Permalink
    Resolved
    0 votes
    You want the private key in ClearOS as it will be doing the cloning, and your public key in GitLab. PuTTy is not the best tool for this. It is better to use ssh-keygen directly in Linux as it puts you private key in the right place (I believe) and you public key with it so you know where to find it. Also PuTTy uses its own file format.

    From PuTTy, you will need to export your private key using the Conversions menu. Put you key in /root/.ssh/id_rsa. I suggest you also put your public key in /root/.ssh/id_rsa.pub. This must be copied out of the Public Key box in PuTTY KeyGen. ssh-keygen should to this for you. Then restart sshd.

    I struggled a bit to get ssh keys working with GitHub. It was easier with GitLab as I'd already done it with GitHub. This should help, especially noting the test bit.

    What you can do with your PuTTy key is keep the private key on your desktop and put the public key in /root/.ssh/authorized_keys, then you can ssh into ClearOS using keys instead of passwords.

    BTW, what are you planning on doing with app-date?
    The reply is currently minimized Show
Your Reply