mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-01 07:47:56 +00:00
Merge pull request #37020 from deads2k/rbac-20-delegated-role
Automatic merge from submit-queue auth delegation role Add a bootstrap role for authentication and authorization delegation. Useful for extension API servers. @kubernetes/sig-auth
This commit is contained in:
commit
4c50486735
@ -194,6 +194,15 @@ func ClusterRoles() []rbac.ClusterRole {
|
|||||||
rbac.NewRule("list", "watch").Groups(legacyGroup).Resources("services", "endpoints").RuleOrDie(),
|
rbac.NewRule("list", "watch").Groups(legacyGroup).Resources("services", "endpoints").RuleOrDie(),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
// a role to use for allowing authentication and authorization delegation
|
||||||
|
ObjectMeta: api.ObjectMeta{Name: "system:auth-delegator"},
|
||||||
|
Rules: []rbac.PolicyRule{
|
||||||
|
// These creates are non-mutating
|
||||||
|
rbac.NewRule("create").Groups(authenticationGroup).Resources("tokenreviews").RuleOrDie(),
|
||||||
|
rbac.NewRule("create").Groups(authorizationGroup).Resources("subjectaccessreviews").RuleOrDie(),
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user