Managing a fine-grained token per organization is cumbersome #138449
Replies: 1 comment
-
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Beta Was this translation helpful? Give feedback.
-
Select Topic Area
General
Body
I'm migrating to the new fine-grained tokens, and I noticed that if I generate a token with my account as the owner, it doesn't have access to any repositories in the orgs I belong to. It seems I need to generate a new token for every organization.
This presents a lot of usability challenges when using git with a credential helper, e.g. you always need to specify the org as the username in all git urls, and if you forget to include the username, it's unclear which token from the credential store will be used.
e.g. let's say I generate a FGT for my personal account "mattfysh" (T1) and for orgA (T2) and orgB (T3). Starting with an empty credential store, I go to pull a private personal repo using
git pull https://github.com/mattfysh/xyz
and it asks for a token password so I provide T1 and it worksI then go to pull a private repo from orgA using
git pull https://github.com/orgA/foo
- and it does not work:I've discovered that I need to supply a username in the git URL to get it to work with a different set of credentials, ie.
git pull https://orgA@github.com/orgA/foo
- on first try this asks for a token, so I provide T2 and it worksHowever, this is now causing a lot of usability challenges in terms of having to always ensure remote URLs are classified with a username. This approach is not surfaced anywhere in the github UI (e.g. when you create a new repo, the git pull command provided does not include a username in the URL) - which has me wondering whether I've approached FGTs the wrong way?
Are there more user-friendly approaches for working with FGTs? Is it really a requirement to generate an FGT per org, requiring multiple accounts in the git credentials store, or have I not found the right setting which would allow me to use a single token across all the repos I have access to, across all orgs I belong to?
Beta Was this translation helpful? Give feedback.
All reactions