Skip to content

Commit ac31e7c

Browse files
ismaelpuertoceph-csi-bot
authored andcommitted
deploy: add RBAC for cephfs provisioner to access volumeattributesclass
The CephFS provisioner needs to read VolumeAttributesClass objects to support MDS pinning via ControllerModifyVolume. Without this the e2e test fails with "cannot get resource volumeattributesclasses in API group storage.k8s.io at the cluster scope". Add the required RBAC rule to both the static deployment manifest and the CephFS Helm chart, matching what RBD already has. Assisted-by: goose <noreply@block.xyz> Signed-off-by: Ismael Puerto Freire <ismaelpf@inditex.com>
1 parent 10aa1df commit ac31e7c

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

charts/ceph-csi-cephfs/templates/provisioner-clusterrole.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,9 @@ rules:
4141
- apiGroups: [""]
4242
resources: ["nodes"]
4343
verbs: ["get", "list","watch"]
44+
- apiGroups: ["storage.k8s.io"]
45+
resources: ["volumeattributesclasses"]
46+
verbs: ["get", "list", "watch"]
4447
{{- if .Values.provisioner.snapshotter.args.enableVolumeGroupSnapshots }}
4548
- apiGroups: ["snapshot.storage.k8s.io"]
4649
resources: ["volumesnapshots"]

deploy/cephfs/kubernetes/csi-provisioner-rbac.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ rules:
8080
- apiGroups: ["replication.storage.openshift.io"]
8181
resources: ["volumegroupreplicationclasses"]
8282
verbs: ["get"]
83+
- apiGroups: ["storage.k8s.io"]
84+
resources: ["volumeattributesclasses"]
85+
verbs: ["get", "list", "watch"]
8386

8487
---
8588
kind: ClusterRoleBinding

0 commit comments

Comments
 (0)