Skip to content

Commit 96f212d

Browse files
committed
Adding separate namespace; removed driver-registrar role; bumped snapshotter version
1 parent d3e2ff0 commit 96f212d

6 files changed

+36
-36
lines changed

deploy/kubernetes/base/kustomization.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
commonLabels:
2-
app: gcp-compute-persistent-disk-csi-driver
2+
k8s-app: gcp-compute-persistent-disk-csi-driver
33
namespace:
4-
default
4+
pdcsi-serving
55
resources:
66
- node.yaml
77
- controller.yaml

deploy/kubernetes/base/setup-cluster.yaml

+26-29
Original file line numberDiff line numberDiff line change
@@ -4,33 +4,6 @@ kind: ServiceAccount
44
metadata:
55
name: csi-node-sa
66

7-
---
8-
9-
kind: ClusterRole
10-
apiVersion: rbac.authorization.k8s.io/v1
11-
metadata:
12-
name: driver-registrar-role
13-
rules:
14-
- apiGroups: [""]
15-
resources: ["events"]
16-
verbs: ["get", "list", "watch", "create", "update", "patch"]
17-
18-
19-
---
20-
21-
kind: ClusterRoleBinding
22-
apiVersion: rbac.authorization.k8s.io/v1
23-
metadata:
24-
name: driver-registrar-binding
25-
subjects:
26-
- kind: ServiceAccount
27-
name: csi-node-sa
28-
namespace: default
29-
roleRef:
30-
kind: ClusterRole
31-
name: driver-registrar-role
32-
apiGroup: rbac.authorization.k8s.io
33-
347
---
358
##### Controller Service Account, Roles, Rolebindings
369
apiVersion: v1
@@ -73,7 +46,7 @@ metadata:
7346
subjects:
7447
- kind: ServiceAccount
7548
name: csi-controller-sa
76-
namespace: default
49+
namespace: pdcsi-serving
7750
roleRef:
7851
kind: ClusterRole
7952
name: external-provisioner-role
@@ -108,8 +81,32 @@ metadata:
10881
subjects:
10982
- kind: ServiceAccount
11083
name: csi-controller-sa
111-
namespace: default
84+
namespace: pdcsi-serving
11285
roleRef:
11386
kind: ClusterRole
11487
name: external-attacher-role
11588
apiGroup: rbac.authorization.k8s.io
89+
90+
---
91+
92+
kind: Role
93+
apiVersion: rbac.authorization.k8s.io/v1
94+
metadata:
95+
name: csi-controller-leaderelection
96+
rules:
97+
- apiGroups: ["coordination.k8s.io"]
98+
resources: ["leases"]
99+
verbs: ["get", "watch", "list", "delete", "update", "create"]
100+
---
101+
kind: RoleBinding
102+
apiVersion: rbac.authorization.k8s.io/v1
103+
metadata:
104+
name: csi-controller-leaderelection-binding
105+
subjects:
106+
- kind: ServiceAccount
107+
name: csi-controller-sa
108+
namespace: pdcsi-serving
109+
roleRef:
110+
kind: Role
111+
name: csi-controller-leaderelection
112+
apiGroup: rbac.authorization.k8s.io

deploy/kubernetes/overlays/alpha/controller_add_resizer.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ spec:
88
containers:
99
- name: csi-resizer
1010
imagePullPolicy: Always
11-
image: quay.io/k8scsi/csi-resizer:canary
11+
image: gke.gcr.io/csi-resizer:v0.2.0-gke.0
1212
args:
1313
- "--v=5"
1414
- "--csi-address=/csi/csi.sock"
1515
volumeMounts:
1616
- name: socket-dir
17-
mountPath: /csi
17+
mountPath: /csi

deploy/kubernetes/overlays/alpha/controller_add_snapshotter.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ spec:
88
containers:
99
- name: csi-snapshotter
1010
imagePullPolicy: Always
11-
image: gke.gcr.io/csi-snapshotter:v1.0.1-gke.0
11+
image: gke.gcr.io/csi-snapshotter:v1.2.0-gke.0
1212
args:
1313
- "--v=5"
1414
- "--csi-address=/csi/csi.sock"

deploy/kubernetes/overlays/alpha/rbac_add_resizer.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ rules:
2121
kind: ClusterRoleBinding
2222
apiVersion: rbac.authorization.k8s.io/v1
2323
metadata:
24-
name: csi-resizer-role
24+
name: csi-controller-resizer-binding
2525
subjects:
2626
- kind: ServiceAccount
2727
name: csi-controller-sa
2828
namespace: default
2929
roleRef:
3030
kind: ClusterRole
3131
name: external-resizer-role
32-
apiGroup: rbac.authorization.k8s.io
32+
apiGroup: rbac.authorization.k8s.io

deploy/kubernetes/overlays/alpha/rbac_add_snapshotter.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ rules:
2626
- apiGroups: ["snapshot.storage.k8s.io"]
2727
resources: ["volumesnapshots"]
2828
verbs: ["get", "list", "watch", "update"]
29+
- apiGroups: ["snapshot.storage.k8s.io"]
30+
resources: ["volumesnapshots/status"]
31+
verbs: ["update"]
2932
- apiGroups: ["apiextensions.k8s.io"]
3033
resources: ["customresourcedefinitions"]
3134
verbs: ["create", "list", "watch", "delete"]

0 commit comments

Comments
 (0)