Skip to content

Add details on using ssh keys#279

Open
ameliaholcomb wants to merge 2 commits into
NASA-IMPACT:mainfrom
ameliaholcomb:patch-1
Open

Add details on using ssh keys#279
ameliaholcomb wants to merge 2 commits into
NASA-IMPACT:mainfrom
ameliaholcomb:patch-1

Conversation

@ameliaholcomb
Copy link
Copy Markdown

Add missing steps to the ssh instructions:

  • An ssh key needs to be generated locally and added to github before adding it to authorized_keys on the hub
  • The local ssh config needs IdentityFile pointing to the private key on the local machine

Add missing steps to the ssh instructions:
- An ssh key needs to be generated locally and added to github before adding it to authorized_keys on the hub
- The local ssh config needs IdentityFile pointing to the private key on the local machine
Copy link
Copy Markdown
Contributor

@maxrjones maxrjones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this gap! One suggestions:

Keep GitHub out of the loop.

Pasting the public key directly into authorized_keys keeps the hub key single-purpose, such that it can't also authenticate to GitHub for git operations, and hub access no longer depends on your GitHub key
list:

# local machine
ssh-keygen -t ed25519 -f ~/.ssh/id_ed25519_hub -C "veda-hub"
# in a JupyterLab terminal on the hub
mkdir -p ~/.ssh && chmod 700 ~/.ssh
cat >> ~/.ssh/authorized_keys   # paste contents of id_ed25519_hub.pub, Ctrl-D
chmod 600 ~/.ssh/authorized_keys

I haven't manually tested this suggestions, and recommend checking that it works as expected before putting them in the doc.

Comment thread user-guide/scientific-computing/ssh.md
@ameliaholcomb
Copy link
Copy Markdown
Author

While I was testing, I noticed that different instructions are also needed if you create a custom named server.
Added documentation for that as well.

All commands tested on my computer (Mac).

Copy link
Copy Markdown
Contributor

@maxrjones maxrjones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants