From a716efc74691305a29b0c90e64b45b28d12a2e22 Mon Sep 17 00:00:00 2001 From: Ruslan Khizhnyak Date: Wed, 8 Nov 2023 12:47:42 +0300 Subject: [PATCH] helm: add annotations for ceph-csi-rbd secret To use mutating webhook to modify secrets. For example banzaicloud vault webhook: https://bank-vaults.dev/docs/mutating-webhook/annotations/ Signed-off-by: Kh Ruslan --- charts/ceph-csi-rbd/templates/secret.yaml | 3 +++ charts/ceph-csi-rbd/values.yaml | 1 + 2 files changed, 4 insertions(+) diff --git a/charts/ceph-csi-rbd/templates/secret.yaml b/charts/ceph-csi-rbd/templates/secret.yaml index 3040bcfd0230..e38a89965f58 100644 --- a/charts/ceph-csi-rbd/templates/secret.yaml +++ b/charts/ceph-csi-rbd/templates/secret.yaml @@ -4,6 +4,9 @@ kind: Secret metadata: name: {{ .Values.secret.name }} namespace: {{ .Release.Namespace }} + {{- with .Values.secret.annotations }} + annotations: {{- . | toYaml | nindent 4 }} + {{- end }} labels: app: {{ include "ceph-csi-rbd.name" . }} chart: {{ include "ceph-csi-rbd.chart" . }} diff --git a/charts/ceph-csi-rbd/values.yaml b/charts/ceph-csi-rbd/values.yaml index 0d43b1671109..ed86620eba82 100644 --- a/charts/ceph-csi-rbd/values.yaml +++ b/charts/ceph-csi-rbd/values.yaml @@ -448,6 +448,7 @@ secret: # Specifies whether the secret should be created create: false name: csi-rbd-secret + annotations: {} # Key values correspond to a user name and its key, as defined in the # ceph cluster. User ID should have required access to the 'pool' # specified in the storage class