You configure the vSphere Kubernetes Service (VKS) Argo CD supervisor service to grant roles based off of users' group membership but the users are not receiving the specified role.
Symptoms:
vSphere Kubernetes Service
The issue occurs because Argo CD is not explicitly requesting the group_names claim from the Identity Broker during the OIDC handshake. By default, OIDC returns the sub (Subject) claim as the unique identifier, which in many modern identity providers is a non-human-readable UUID. Without the group_names scope and claim mapping, Argo CD cannot identify the user's group memberships to apply RBAC policies.
To resolve this issue, update the Argo CD configuration to request the group_names claim and map it to the RBAC scopes.
Modify the Argo CD custom resource (CR) to include the specific claims and scopes required by the Identity Broker:
kubectl edit argocd argocd -n <ARGOCD_NAMESPACE>
Add the group_names attribute to requestedIDTokenClaims and group_names to the scopes attribute:
...
spec:
enableLoadBalancer: true
oidc:
clientID: <CLIENT_ID>
clientSecret: <CLIENT_SECRET>
enabled: true
insecure: true
issuer: <ISSUER_URL>
requestedIDTokenClaims:
group_names:
essential: true
requestedScopes:
- openid
- group
- profile
- email
rbac:
scopes: '[group_names]'
policy: |
g, <GROUP_NAME>, role:admin
...
Restart the Argo CD server deployment to ensure the changes take effect:
kubectl rollout restart deployment argocd-server -n <ARGOCD_NAMESPACE>