From 979721c7706215f543f732a1e15e562cc451c8b3 Mon Sep 17 00:00:00 2001 From: mazmar Date: Tue, 27 Jan 2026 11:12:43 +0100 Subject: [PATCH 1/2] feat: allow extra volumes and volume mounts for CSI secrets and other volumes Signed-off-by: Matus Szepe --- operator/templates/manager/manager.yaml | 16 ++++++++++++--- operator/values.yaml | 26 +++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 3 deletions(-) diff --git a/operator/templates/manager/manager.yaml b/operator/templates/manager/manager.yaml index a0ea088958..a6661074e8 100644 --- a/operator/templates/manager/manager.yaml +++ b/operator/templates/manager/manager.yaml @@ -19,11 +19,16 @@ spec: labels: control-plane: securecodebox-controller-manager spec: - {{- if .Values.customCACertificate.existingCertificate }} + {{- if or .Values.customCACertificate.existingCertificate .Values.extraVolumes }} volumes: + {{- if .Values.customCACertificate.existingCertificate }} - name: ca-certificate configMap: name: {{ .Values.customCACertificate.existingCertificate }} + {{- end }} + {{- range .Values.extraVolumes }} + - {{ toYaml . | nindent 10 }} + {{- end }} {{- end }} serviceAccountName: {{ .Values.serviceAccount.name }} securityContext: @@ -38,11 +43,16 @@ spec: args: - --leader-elect image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.Version }}" - {{- if .Values.customCACertificate.existingCertificate }} + {{- if or .Values.customCACertificate.existingCertificate .Values.extraVolumeMounts }} volumeMounts: + {{- if .Values.customCACertificate.existingCertificate }} - name: ca-certificate mountPath: /etc/ssl/certs/{{ .Values.customCACertificate.certificate }} subPath: {{ .Values.customCACertificate.certificate }} + {{- end }} + {{- range .Values.extraVolumeMounts }} + - {{ toYaml . | nindent 14 }} + {{- end }} {{- end }} imagePullPolicy: {{ .Values.image.pullPolicy }} name: manager @@ -90,7 +100,7 @@ spec: value: {{ .Values.s3.bucket }} {{- if .Values.s3.port }} - name: S3_PORT - value: {{ .Values.s3.port }} + value: {{ .Values.s3.port | quote }} {{- end }} - name: S3_AUTH_TYPE value: {{ .Values.s3.authType }} diff --git a/operator/values.yaml b/operator/values.yaml index e77448e746..468a21c4f2 100644 --- a/operator/values.yaml +++ b/operator/values.yaml @@ -29,6 +29,32 @@ customCACertificate: # -- key in the configmap holding the certificate(s) certificate: "public.crt" + +# -- Additional volumes to be mounted to the operator deployment +extraVolumes: [ ] +# Example: +# extraVolumes: +# - name: ssl-certificates +# secret: +# secretName: ssl-cert-secret +# - name: config-volume +# configMap: +# name: operator-config +# - name: cache-volume +# emptyDir: {} + +# -- Additional volume mounts to be mounted to the operator deployment +extraVolumeMounts: [ ] +# Example: +# extraVolumeMounts: +# - name: ssl-certificates +# mountPath: /etc/ssl/certs +# readOnly: true +# - name: config-volume +# mountPath: /etc/config +# - name: cache-volume +# mountPath: /cache + serviceAccount: # -- Name of the serviceAccount the operator uses to talk to the k8s api name: securecodebox-operator From 00b46c91c9a413909e5b8c373a16f5abd856f85d Mon Sep 17 00:00:00 2001 From: Matus Szepe Date: Wed, 28 Jan 2026 16:51:09 +0100 Subject: [PATCH 2/2] added to contributors Signed-off-by: Matus Szepe --- CONTRIBUTORS.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index d6071c23be..a8a78389ed 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -62,3 +62,4 @@ Committing with `git commit -s` will add the sign-off at the end of the commit m - Joel Saß - Patrick Weiss - Conleth Kennedy +- Matus Szepe