Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: github users via API #191

Conversation

bavarianbidi
Copy link
Contributor

@bavarianbidi bavarianbidi commented Oct 2, 2023

if a GitHub Enterprise instance requires authentication for every endpoint it's not possible to fetch the public keys via /.keys

With a dedicated PAT with the scope read:public_key it's possible to fetch the public keys via the API

This PR will also add some some information to the ~/.upterm/upterm.log to make it more transparent if public keys didn't get found.

TODO:

  • get to know where to put the documentation
  • Should we extend the cobra.Command.Long section as well to document all the github/gitlab/sourceHut user possibilities as well?

if a GitHub Enterprise instance requires authentication for every
endpoint it's not possible to fetch the public keys via
<URL>/<username>.keys

With a dedicated PAT with the scope read:public_key it's possible to
fetch the public keys via the API

Signed-off-by: Mario Constanti <mario.constanti@mercedes-benz.com>
@owenthereal
Copy link
Owner

Thanks for the contributions! Instead of adding more flags to upterm, I would prefer integrating upterm with the gh CLI and get the GH token/host from gh CLI's storage: #200. One pro is that if one has the gh CLI set up, upterm will adopt the token/host from it. If gh is not set up, setting GH_TOKEN & GH_HOST will also get upterm to call GH API with the specified token & host (just like how the gh CLI works). This should be sufficient to meet the GitHub Entperise use case.

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.

None yet

2 participants