Skip to content
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

fix sso login and fetch user groups #33

Merged
merged 2 commits into from
Jan 31, 2025
Merged

Conversation

srm6867
Copy link

@srm6867 srm6867 commented Jan 29, 2025

  1. Fixes sso login by fetching sso-group id from tokeninfo
  2. Adds user groups in token

this is how the groups in token looks like -

"groups": [
    "Azure",
    "shubham-dev-1-default-test-member",
    "shubham-dev-1-default-service-admin"
  ]

where

  • "Azure" is user group name

  • and all others are generated group name based on roles -
    eg - shubham-dev-1-default-service-admin
    shubham-dev-1 -> customer shortname derived from keystone auth url
    default -> domain name
    service -> project name
    admin -> role of that user in service project

Use case -

  1. Management cluster - the role based group names are used in configuring rbac for tenant namespace.

  2. Workload cluster - the group names of user, Azure in this case can be used by workload cluster admin to configure rbac on workload cluster.

Copy link

@psarwate psarwate left a comment

Choose a reason for hiding this comment

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

/lgtm

@srm6867 srm6867 requested a review from shalaka-pf9 January 31, 2025 09:39
@srm6867 srm6867 merged commit 45cd63b into master Jan 31, 2025
1 of 6 checks passed
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.

3 participants