Skip to content

enabled default github identity resolver - #121

Merged
christophe-f merged 2 commits into
redhat-developer:mainfrom
raffaelespazzoli:fixes#116
Mar 16, 2023
Merged

enabled default github identity resolver#121
christophe-f merged 2 commits into
redhat-developer:mainfrom
raffaelespazzoli:fixes#116

Conversation

@raffaelespazzoli

Copy link
Copy Markdown
Contributor

Description

enabled default github identity resolver. This change worked for me. But it may need some conditional logic to coexist with other identity resolved. Basically one can assume that given how a user was authenticated, there is an identity resolved that applies better than others. And then perhaps have a default one (the one I commented out).
Not sure how to write that conditional logic. This is better tested only after #120 is merged and it needs that data to do the mapping.

Which issue(s) does this PR fix

PR acceptance criteria

Put an x in the boxes that apply

  • GitHub Actions are completed and successful
  • Unit Tests are updated and passing
  • E2E Tests are updated and passing
  • Documentation is updated if necessary

How to test changes / Special notes to the reviewer

Comment thread packages/backend/src/plugins/auth.ts Outdated
Comment on lines +40 to +48
// resolver(_, ctx) {
// const userRef = 'user:default/guest'; // Must be a full entity reference
// return ctx.issueToken({
// claims: {
// sub: userRef, // The user's own identity
// ent: [userRef], // A list of identities that the user claims ownership through
// },
// });
// },

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can delete the unused section

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@christophe-f

Copy link
Copy Markdown
Contributor

LGTM

@christophe-f
christophe-f self-requested a review March 16, 2023 15:07
@christophe-f
christophe-f merged commit a0284f4 into redhat-developer:main Mar 16, 2023
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.

Enable github identity resolver

2 participants