You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to be able to pass multiple tokens via the GITHUB_TOKEN environment variable.
Why do you want this feature?
GitHub tokens need to match the expected scopes for a package to authenticate to it. While the code serverGITHUB_TOKEN env var allows us to inject a single token, if we have multiple packages we want to authenticate, but which require different token scopes, we can't inject multiple tokens via this method.
Are there any workarounds to get this functionality today?
Not that I am aware of. It would be good to create a mapping of all scopes (not just order of permissions, but inclusion of permissions) -> a single token which grants such scopes.
Are you interested in submitting a PR for this?
Yes.
The text was updated successfully, but these errors were encountered:
any pointers on where to get started @code-asher? I assume src/node/cli.ts and patches/github-auth.diff? any other areas i might need to pay attention to?
Yup exactly. You would have to update the tests in test/unit/node/cli.test.ts as well but I think those are all the files you would need to touch.
One interesting question is what to do if both GITHUB_TOKEN and --github-auth are set. We could merge them although I think having the CLI flag override the env var is probably more in keeping with how the other flags work.
What is your suggestion?
I would like to be able to pass multiple tokens via the
GITHUB_TOKEN
environment variable.Why do you want this feature?
GitHub tokens need to match the expected scopes for a package to authenticate to it. While the
code server
GITHUB_TOKEN
env var allows us to inject a single token, if we have multiple packages we want to authenticate, but which require different token scopes, we can't inject multiple tokens via this method.Are there any workarounds to get this functionality today?
Not that I am aware of. It would be good to create a mapping of all scopes (not just order of permissions, but inclusion of permissions) -> a single token which grants such scopes.
Are you interested in submitting a PR for this?
Yes.
The text was updated successfully, but these errors were encountered: