mirror of
https://github.com/open-cluster-management-io/ocm.git
synced 2026-05-19 07:37:40 +00:00
39 lines
1.5 KiB
YAML
39 lines
1.5 KiB
YAML
apiVersion: rbac.authorization.k8s.io/v1
|
|
kind: ClusterRole
|
|
metadata:
|
|
name: klusterlet
|
|
rules:
|
|
# Allow the registration-operator to create workload
|
|
- apiGroups: [""]
|
|
resources: ["secrets", "configmaps", "serviceaccounts"]
|
|
verbs: ["create", "get", "list", "update", "watch", "patch", "delete"]
|
|
- apiGroups: ["authorization.k8s.io"]
|
|
resources: ["subjectaccessreviews"]
|
|
verbs: ["create"]
|
|
- apiGroups: [""]
|
|
resources: ["namespaces"]
|
|
verbs: ["create", "get", "list", "watch", "delete"]
|
|
- apiGroups: ["", "events.k8s.io"]
|
|
resources: ["events"]
|
|
verbs: ["create", "patch", "update"]
|
|
- apiGroups: ["apps"]
|
|
resources: ["deployments"]
|
|
verbs: ["create", "get", "list", "update", "watch", "patch", "delete"]
|
|
- apiGroups: ["rbac.authorization.k8s.io"]
|
|
resources: ["clusterrolebindings", "rolebindings"]
|
|
verbs: ["create", "get", "list", "update", "watch", "patch", "delete"]
|
|
- apiGroups: ["rbac.authorization.k8s.io"]
|
|
resources: ["clusterroles", "roles"]
|
|
verbs: ["create", "get", "list", "update", "watch", "patch", "delete", "escalate", "bind"]
|
|
# Allow the registration-operator to create crds
|
|
- apiGroups: ["apiextensions.k8s.io"]
|
|
resources: ["customresourcedefinitions"]
|
|
verbs: ["create", "get", "list", "update", "watch", "patch", "delete"]
|
|
# Allow the registration-operator to manage klusterlet apis.
|
|
- apiGroups: ["operator.open-cluster-management.io"]
|
|
resources: ["klusterlets"]
|
|
verbs: ["get", "list", "watch", "update", "patch", "delete"]
|
|
- apiGroups: ["operator.open-cluster-management.io"]
|
|
resources: ["klusterlets/status"]
|
|
verbs: ["update", "patch"]
|