Skip to content

Commit 44e43fa

Browse files
authored
Merge pull request #12 from Madhan-SWE/feature_remove_pvm_instance_id_v2
Volume resize functionality added
2 parents 356f1ab + f2a8622 commit 44e43fa

File tree

3 files changed

+54
-0
lines changed

3 files changed

+54
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
kind: ClusterRole
3+
apiVersion: rbac.authorization.k8s.io/v1
4+
metadata:
5+
name: powervs-external-resizer-role
6+
labels:
7+
app.kubernetes.io/name: powervs-csi-driver
8+
rules:
9+
# The following rule should be uncommented for plugins that require secrets
10+
# for provisioning.
11+
- apiGroups: [ "" ]
12+
resources: [ "persistentvolumes" ]
13+
verbs: [ "get", "list", "watch", "update", "patch" ]
14+
- apiGroups: [ "" ]
15+
resources: [ "persistentvolumeclaims" ]
16+
verbs: [ "get", "list", "watch" ]
17+
- apiGroups: [ "" ]
18+
resources: [ "persistentvolumeclaims/status" ]
19+
verbs: [ "update", "patch" ]
20+
- apiGroups: [ "storage.k8s.io" ]
21+
resources: [ "storageclasses" ]
22+
verbs: [ "get", "list", "watch" ]
23+
- apiGroups: [ "" ]
24+
resources: [ "events" ]
25+
verbs: [ "list", "watch", "create", "update", "patch" ]
26+
- apiGroups: [ "" ]
27+
resources: [ "pods" ]
28+
verbs: [ "get", "list", "watch" ]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
---
2+
kind: ClusterRoleBinding
3+
apiVersion: rbac.authorization.k8s.io/v1
4+
metadata:
5+
name: powervs-csi-resizer-binding
6+
labels:
7+
app.kubernetes.io/name: powervs-csi-driver
8+
subjects:
9+
- kind: ServiceAccount
10+
name: powervs-csi-controller-sa
11+
namespace: kube-system
12+
roleRef:
13+
kind: ClusterRole
14+
name: powervs-external-resizer-role
15+
apiGroup: rbac.authorization.k8s.io

deploy/kubernetes/base/controller.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,17 @@ spec:
9090
volumeMounts:
9191
- name: socket-dir
9292
mountPath: /var/lib/csi/sockets/pluginproxy/
93+
- name: csi-resizer
94+
image: k8s.gcr.io/sig-storage/csi-resizer:v1.1.0
95+
args:
96+
- --csi-address=$(ADDRESS)
97+
- --v=2
98+
env:
99+
- name: ADDRESS
100+
value: /var/lib/csi/sockets/pluginproxy/csi.sock
101+
volumeMounts:
102+
- name: socket-dir
103+
mountPath: /var/lib/csi/sockets/pluginproxy/
93104
- name: liveness-probe
94105
image: k8s.gcr.io/sig-storage/livenessprobe:v2.1.0
95106
args:

0 commit comments

Comments
 (0)