Skip to content

Commit 0c81307

Browse files
Merge pull request #15908 from simo5/nonorm
Automatic merge from submit-queue (batch tested with PRs 15787, 15908) Stop using NormalizeResources in bootstrap policy Just removed it. Fixes #15821
2 parents c1e9505 + cacd579 commit 0c81307

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

pkg/cmd/server/bootstrappolicy/policy.go

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ var (
8888
)
8989

9090
func GetBootstrapOpenshiftRoles(openshiftNamespace string) []rbac.Role {
91-
roles := []rbac.Role{
91+
return []rbac.Role{
9292
{
9393
ObjectMeta: metav1.ObjectMeta{
9494
Name: OpenshiftSharedResourceViewRoleName,
@@ -111,17 +111,6 @@ func GetBootstrapOpenshiftRoles(openshiftNamespace string) []rbac.Role {
111111
},
112112
},
113113
}
114-
115-
// we don't want to expose the resourcegroups externally because it makes it very difficult for customers to learn from
116-
// our default roles and hard for them to reason about what power they are granting their users
117-
for i := range roles {
118-
for j := range roles[i].Rules {
119-
roles[i].Rules[j].Resources = authorizationapi.NormalizeResources(sets.NewString(roles[i].Rules[j].Resources...)).List()
120-
}
121-
}
122-
123-
return roles
124-
125114
}
126115

127116
func GetOpenshiftBootstrapClusterRoles() []rbac.ClusterRole {

0 commit comments

Comments
 (0)