From 938003d7e41fb064b5bf71865f2363d06d1dbb61 Mon Sep 17 00:00:00 2001 From: Sebastian Woehrl Date: Wed, 12 Jan 2022 15:52:36 +0100 Subject: [PATCH] Add extraVolumes to helm chart --- deploy/helm/opsbot/templates/deployment.yaml | 9 +++++++++ deploy/helm/opsbot/values.yaml | 8 ++++++++ 2 files changed, 17 insertions(+) diff --git a/deploy/helm/opsbot/templates/deployment.yaml b/deploy/helm/opsbot/templates/deployment.yaml index b913fc1..46e3d8a 100644 --- a/deploy/helm/opsbot/templates/deployment.yaml +++ b/deploy/helm/opsbot/templates/deployment.yaml @@ -48,6 +48,10 @@ spec: - name: plugins mountPath: /additional_plugins {{- end }} + {{- range .Values.extraVolumes }} + - name: {{ .name | required "extraVolumes .name is required" }} + mountPath: {{ .mountPath | required "extraVolumes .mountPath is required "}} + {{- end }} env: - name: OPSBOT_CONFIG_FILE value: /config/config.yaml @@ -76,3 +80,8 @@ spec: configMap: name: {{ include "opsbot.fullname" . }}-plugins {{- end }} + {{- range .Values.extraVolumes }} + - name: {{ .name | required "extraVolumes .name is required" }} + {{- toYaml .def | nindent 10 }} + {{- end }} + diff --git a/deploy/helm/opsbot/values.yaml b/deploy/helm/opsbot/values.yaml index d36f4d0..9361222 100644 --- a/deploy/helm/opsbot/values.yaml +++ b/deploy/helm/opsbot/values.yaml @@ -48,3 +48,11 @@ nodeSelector: {} tolerations: [] affinity: {} + +# Use this option to mount extra volumes into the opsbot pod +extraVolumes: [] + # - name: persistence + # def: + # persistentVolumeClaim: + # claimName: opsbot-persistence + # mountPath: /mnt/persistence