File tree Expand file tree Collapse file tree 1 file changed +25
-1
lines changed Expand file tree Collapse file tree 1 file changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -151,6 +151,8 @@ the RBAC rules that grant the Agent access.
151151
152152The Sync Agent needs to
153153
154+ * access the workspace of its `APIExport`,
155+ * get the `LogicalCluster`,
154156* manage its `APIExport`,
155157* manage `APIResourceSchemas` and
156158* access the virtual workspace for its `APIExport`.
@@ -163,6 +165,15 @@ kind: ClusterRole
163165metadata:
164166 name: api-syncagent-mango
165167rules:
168+ # get the LogicalCluster
169+ - apiGroups:
170+ - core.kcp.io
171+ resources:
172+ - logicalclusters
173+ resourceNames:
174+ - cluster
175+ verbs:
176+ - get
166177 # manage its APIExport
167178 - apiGroups:
168179 - apis.kcp.io
@@ -200,14 +211,27 @@ rules:
200211apiVersion: rbac.authorization.k8s.io/v1
201212kind: ClusterRoleBinding
202213metadata:
203- name: api-syncagent-columbo: mango- system
214+ name: api-syncagent-mango: system
204215roleRef:
205216 apiGroup: rbac.authorization.k8s.io
206217 kind: ClusterRole
207218 name: api-syncagent-mango
208219subjects:
209220 - kind: User
210221 name: api-syncagent-mango
222+
223+ ---
224+ apiVersion: rbac.authorization.k8s.io/v1
225+ kind: ClusterRoleBinding
226+ metadata:
227+ name: api-syncagent-mango:access
228+ roleRef:
229+ apiGroup: rbac.authorization.k8s.io
230+ kind: ClusterRole
231+ name: system:kcp:workspace:access
232+ subjects:
233+ - kind: User
234+ name: api-syncagent-mango
211235` ` `
212236
213237# # Publish Resources
You can’t perform that action at this time.
0 commit comments