-
Notifications
You must be signed in to change notification settings - Fork 71
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 OAuth authentication with embededOAuthAPI #178
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Can one of the admins verify this patch? |
xbaran4
force-pushed
the
oauth2-factory
branch
from
November 24, 2021 23:07
a91de91
to
ac1ad86
Compare
xbaran4
changed the title
fix: adapting requests to new github api
feat: GitHub OAuth authentication with embededOAuthAPI
Nov 24, 2021
xbaran4
force-pushed
the
oauth2-factory
branch
from
November 24, 2021 23:14
ac1ad86
to
76b68c0
Compare
Signed-off-by: Pavol Baran <pbaran@redhat.com>
xbaran4
force-pushed
the
oauth2-factory
branch
from
November 24, 2021 23:55
76b68c0
to
6b17bd5
Compare
xbaran4
requested review from
yhontyk,
ibuziuk,
MichalMaler,
nickboldt,
skabashnyuk,
sleshchenko and
themr0c
as code owners
November 25, 2021 00:00
skabashnyuk
reviewed
Nov 25, 2021
...rc/main/java/org/eclipse/che/api/factory/server/github/GithubPersonalAccessTokenFetcher.java
Outdated
Show resolved
Hide resolved
skabashnyuk
reviewed
Nov 25, 2021
...e-api-auth-github/src/main/java/org/eclipse/che/security/oauth/GitHubOAuthAuthenticator.java
Outdated
Show resolved
Hide resolved
skabashnyuk
reviewed
Nov 25, 2021
...th-github/src/main/java/org/eclipse/che/security/oauth/GitHubOAuthAuthenticatorProvider.java
Outdated
Show resolved
Hide resolved
skabashnyuk
reviewed
Nov 25, 2021
...th-github/src/main/java/org/eclipse/che/security/oauth/GitHubOAuthAuthenticatorProvider.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Pavol Baran <pbaran@redhat.com>
skabashnyuk
reviewed
Nov 26, 2021
...th-github/src/main/java/org/eclipse/che/security/oauth/GitHubOAuthAuthenticatorProvider.java
Show resolved
Hide resolved
...th-github/src/main/java/org/eclipse/che/security/oauth/GitHubOAuthAuthenticatorProvider.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Pavol Baran <pbaran@redhat.com>
Signed-off-by: Pavol Baran <pbaran@redhat.com>
xbaran4
force-pushed
the
oauth2-factory
branch
from
November 26, 2021 19:26
0172aca
to
1570683
Compare
Signed-off-by: Pavol Baran <pbaran@redhat.com>
Signed-off-by: Pavol Baran <pbaran@redhat.com>
sparkoo
approved these changes
Nov 29, 2021
skabashnyuk
approved these changes
Nov 30, 2021
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.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Signed-off-by: xbaran4 pbaran@redhat.com
What does this PR do?
Screenshot/screencast of this PR
Enables OAuth flow for GitHub without Keycloak. Using embededOAuthAPI
What issues does this PR fix or reference?
eclipse-che/che#20497
How to test this PR?
1.Deploy quay.io/pbaran/che-server:github10 with devworkspaces.
2. Create GitHub OAuth App in your account. (https://docs.github.com/en/developers/apps/building-oauth-apps/creating-an-oauth-app)
2.1 Application name => Che (But should not matter)
2.2 Homepage URL => $CHE_HOST
2.3 Authorization callback URL => $CHE_HOST/api/oauth/callback
2.4 Register application and generate a new client secret
3. Use your client id and client secret to create k8s github-oauth-config secret:
(https://www.eclipse.org/che/docs/che-7/administration-guide/configuring-authorization/#configuring-github-oauth_che)
4. Right now you have to restart che-server pod to have the credentials mounted in che.
5. Try to create factory from private repo on your github.
Note: right now you have to have older dashboard version i.e. 7.39.2 because of a bug: eclipse-che/che#20835
PR Checklist
As the author of this Pull Request I made sure that:
What issues does this PR fix or reference
andHow to test this PR
completedReviewers
Reviewers, please comment how you tested the PR when approving it.