Skip to content

Commit 4253b9d

Browse files
authored
Correct apigroup for role/rolebingins perms in single-namespace rbac files. (#691)
1 parent 57bb542 commit 4253b9d

File tree

4 files changed

+62
-62
lines changed

4 files changed

+62
-62
lines changed

config/rbac/role.yaml

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -39,26 +39,6 @@ rules:
3939
- patch
4040
- update
4141
- watch
42-
- apiGroups:
43-
- ""
44-
resources:
45-
- rolebindings
46-
verbs:
47-
- create
48-
- get
49-
- list
50-
- patch
51-
- watch
52-
- apiGroups:
53-
- ""
54-
resources:
55-
- roles
56-
verbs:
57-
- create
58-
- get
59-
- list
60-
- patch
61-
- watch
6242
- apiGroups:
6343
- ""
6444
resources:
@@ -151,3 +131,23 @@ rules:
151131
- patch
152132
- update
153133
- watch
134+
- apiGroups:
135+
- rbac.authorization.k8s.io
136+
resources:
137+
- rolebindings
138+
verbs:
139+
- create
140+
- get
141+
- list
142+
- patch
143+
- watch
144+
- apiGroups:
145+
- rbac.authorization.k8s.io
146+
resources:
147+
- roles
148+
verbs:
149+
- create
150+
- get
151+
- list
152+
- patch
153+
- watch

deploy/bundle.yaml

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10152,26 +10152,6 @@ rules:
1015210152
- patch
1015310153
- update
1015410154
- watch
10155-
- apiGroups:
10156-
- ""
10157-
resources:
10158-
- rolebindings
10159-
verbs:
10160-
- create
10161-
- get
10162-
- list
10163-
- patch
10164-
- watch
10165-
- apiGroups:
10166-
- ""
10167-
resources:
10168-
- roles
10169-
verbs:
10170-
- create
10171-
- get
10172-
- list
10173-
- patch
10174-
- watch
1017510155
- apiGroups:
1017610156
- ""
1017710157
resources:
@@ -10264,6 +10244,26 @@ rules:
1026410244
- patch
1026510245
- update
1026610246
- watch
10247+
- apiGroups:
10248+
- rbac.authorization.k8s.io
10249+
resources:
10250+
- rolebindings
10251+
verbs:
10252+
- create
10253+
- get
10254+
- list
10255+
- patch
10256+
- watch
10257+
- apiGroups:
10258+
- rbac.authorization.k8s.io
10259+
resources:
10260+
- roles
10261+
verbs:
10262+
- create
10263+
- get
10264+
- list
10265+
- patch
10266+
- watch
1026710267
---
1026810268
apiVersion: rbac.authorization.k8s.io/v1
1026910269
kind: RoleBinding

deploy/rbac.yaml

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -80,26 +80,6 @@ rules:
8080
- patch
8181
- update
8282
- watch
83-
- apiGroups:
84-
- ""
85-
resources:
86-
- rolebindings
87-
verbs:
88-
- create
89-
- get
90-
- list
91-
- patch
92-
- watch
93-
- apiGroups:
94-
- ""
95-
resources:
96-
- roles
97-
verbs:
98-
- create
99-
- get
100-
- list
101-
- patch
102-
- watch
10383
- apiGroups:
10484
- ""
10585
resources:
@@ -192,6 +172,26 @@ rules:
192172
- patch
193173
- update
194174
- watch
175+
- apiGroups:
176+
- rbac.authorization.k8s.io
177+
resources:
178+
- rolebindings
179+
verbs:
180+
- create
181+
- get
182+
- list
183+
- patch
184+
- watch
185+
- apiGroups:
186+
- rbac.authorization.k8s.io
187+
resources:
188+
- roles
189+
verbs:
190+
- create
191+
- get
192+
- list
193+
- patch
194+
- watch
195195
---
196196
apiVersion: rbac.authorization.k8s.io/v1
197197
kind: RoleBinding

pkg/controller/ps/controller.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ type PerconaServerMySQLReconciler struct {
7272
//+kubebuilder:rbac:groups=apps,resources=statefulsets;deployments,verbs=get;list;watch;create;update;patch;delete
7373
//+kubebuilder:rbac:groups=certmanager.k8s.io;cert-manager.io,resources=issuers;certificates,verbs=get;list;watch;create;update;patch;delete;deletecollection
7474
//+kubebuilder:rbac:groups="",resources=serviceaccounts,verbs=get;list;watch;create;patch
75-
//+kubebuilder:rbac:groups="",resources=rolebindings,verbs=get;list;watch;create;patch
76-
//+kubebuilder:rbac:groups="",resources=roles,verbs=get;list;watch;create;patch
75+
//+kubebuilder:rbac:groups="rbac.authorization.k8s.io",resources=rolebindings,verbs=get;list;watch;create;patch
76+
//+kubebuilder:rbac:groups="rbac.authorization.k8s.io",resources=roles,verbs=get;list;watch;create;patch
7777

7878
// SetupWithManager sets up the controller with the Manager.
7979
func (r *PerconaServerMySQLReconciler) SetupWithManager(mgr ctrl.Manager) error {

0 commit comments

Comments
 (0)