-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Migrate GitHub OAuth App to GitHub App #11942
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't tested this locally, but it seems it could work.
I understand our "Login/Signup with GitHub" button will now point to the new GitHub App, right?
If you have this environment already setup locally, can you record a small GIF that shows the workflow to understand what is the UX? |
Yep.
Screencast.From.2025-01-28.16-17-42.mp4The old login option will be hidden in production, of course. |
The UX looks great to me! 🎉 I see we are showing both GitHub integrations in the user settings, which could be a little confusing. Maybe we can hide the old integration once the new one is approved if we want to. |
It seems you are writing the code for a bigger migration that we talked for the first chunk of work. We wanted to scope this work down to be able to login with GitHub Application first. That will give us a lot of information about the workflow and confirm this is possible. Once there, we should be able to move forward with webhooks, clonning and all the other integrations we want to build on top of GitHub Application. I'm not saying this work is wrong --we definitely need/want it-- but it will be safer to move forward using smaller steps to avoid such a big change all at once. |
That was already done. Exposing the new GH app as login option is the last step, we can't expose it first without having the integration working since new users won't be able to import projects. My plan is:
|
Ah, you are right here. I was only thinking about old users with a OAuth application in place already 🙃 |
…s to projects Our current logic allows any user (or member) to link a public repository to a project, this was fine since we use the user session to create the webhook and ssh key on .com, and if they don't have permissions, nothing will happen. But with #11942 operations won't be done on behalf of the user, but the installation, so we need to make sure that the user has permissions to link the repository to the project.
A small refactor extracted from #11942
A small refactor extracted from #11942
A small refactor extracted from #11942
Extracted from #11942. Instead of getting a service for the user and manually syncing the repositories, this abstracts syncing the access to the repositories in another method. This is since with GH apps, syncing the access to the repositories is done in a different way.
Ref #11780