Skip to content

Setting up SSH Permissions

Kelly Werner edited this page Sep 6, 2022 · 2 revisions

To be able to push/pull to/from repositories, the SSH keys must be set for each local machine (e.g., your Cheyenne account and your work laptop). To set this up, follow these instructions:

On your local machine

  1. Go to ~/.ssh and type the command ls -a to see if you have a file named "id_rsa.pub" If so, skip to the "On GitHub" section below.
  2. If you do not have a public SSH key, you'll need to create one. Type the command ssh-keygen -t rsa
  3. In the prompt, enter a path and file name to which you'll save your SSH key (typically /your-home-directory/.ssh/id_rsa).
  4. Hit "enter" twice to bypass the passphrase option. You should now have files called, for e.g., id_rsa and id_rsa.pub.

On GitHub

  1. Log into your account.
  2. Click on your profile icon in the top right of the page.
  3. Choose 'Settings.'
  4. Click on "SSH and GPG keys" in the left side menu.
  5. Click the green "New SSH key" near the top of the page.
  6. Choose a title for that key (this can be anything you want - for e.g., "My Cheyenne Key."
  7. Key type = Authentication Key
  8. Go back to your local machine and open the file called "id_rsa.pub" and copy the full content. Then paste it into the GitHub window for "Key."
  9. Click the green "Add SSH key" button.

You should now be able to work between GitHub and your local machine without needing a username or password each time.