forked from kubernetes-sigs/gcp-filestore-csi-driver
-
Notifications
You must be signed in to change notification settings - Fork 0
/
no_snapshotter_roles.yaml
34 lines (34 loc) · 1.06 KB
/
no_snapshotter_roles.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# TODO: Check if we can remove the snapshot, snapshotcontent get list roles for provisioner
$patch: delete
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: gcp-filestore-csi-snapshotter-role
rules:
- apiGroups: [""]
resources: ["events"]
verbs: ["list", "watch", "create", "update", "patch"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotclasses"]
verbs: ["get", "list", "watch"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotcontents"]
verbs: ["create", "get", "list", "watch", "update", "delete"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotcontents/status"]
verbs: ["update"]
---
$patch: delete
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: gcp-filestore-csi-snapshotter-binding
subjects:
- kind: ServiceAccount
name: gcp-filestore-csi-controller-sa
namespace: gcp-filestore-csi-driver
roleRef:
kind: ClusterRole
name: gcp-filestore-csi-snapshotter-role
apiGroup: rbac.authorization.k8s.io
---