Configuring the access to GitHub with SSH

ssh-keygen -t ed25519 -C "winappdev@gmail.com"
# /home/dmitriano/.ssh/id_rsa_github
# and empty passphrase
nano .ssh/config
Host github.com
 HostName github.com
 IdentityFile ~/.ssh/id_rsa_github
stat -c %a ~/.ssh/config
chmod 600 ~/.ssh/config

Go to https://github.com/settings/keys and import the public key:

Clone a repository:

git clone git@github.com:dmitriano/bbs.git

4 Responses to Configuring the access to GitHub with SSH

  1. superadmin says:

    Create SSH user with limited privileges to only use Git repository

    https://serverfault.com/questions/170048/create-ssh-user-with-limited-privileges-to-only-use-git-repository

    You might consider using gitolite under a single user instead of setting up multiple git-shell users (and the required group and group permissions so they can share access to the repositories).

    gitolite runs under a single, normal user on the server and uses SSH public keys to differentiate access to Git repositories (see “how gitolite uses ssh” for some of the details of how gitolite does its SSH-based identification). gitolite offers per-repository, per-branch, and even some per-path access control.

  2. superadmin says:

    How can I set up password-less SSH login?

    https://askubuntu.com/questions/46930/how-can-i-set-up-password-less-ssh-login

    Execute this command (if you already have an SSH key, you can skip this step):

    ssh-keygen
    Then you’ll need to copy the new key to your server:

    ssh-copy-id user@host
    ## or if your server uses custom port no:
    ssh-copy-id “user@host -p 1234”

  3. superadmin says:

    How to Connect to SSH Without a Password
    https://builtin.com/articles/ssh-without-password
    ssh-keygen
    ssh-copy-id dmitriano@developernote.com
    ssh dmitriano@developernote.com

Leave a Reply

Your email address will not be published. Required fields are marked *