From 079e4cd59c3b6cfd86f8cd4392969912f788368d Mon Sep 17 00:00:00 2001 From: Bastian Eicher Date: Fri, 5 May 2023 11:31:29 +0200 Subject: [PATCH] Fixed hot-reload for additional ConfigMaps --- charts/generic-service/templates/controller.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/charts/generic-service/templates/controller.yaml b/charts/generic-service/templates/controller.yaml index 0c5afcc..1875cc6 100644 --- a/charts/generic-service/templates/controller.yaml +++ b/charts/generic-service/templates/controller.yaml @@ -263,8 +263,8 @@ spec: {{- end }} {{- range .Values.additionalConfigs }} - name: config-{{ tpl . $ }} - subPath: data.yaml - mountPath: /config/{{ tpl . $ }}.yaml + # Mount entire directory instead of just file to enable hot-reload + mountPath: '/additional-configs/{{ tpl . $ }}' {{- end }} {{- range $name, $secret := .Values.secrets }} - name: {{ tpl $name $ }} @@ -378,7 +378,7 @@ spec: {{- if or .Values.config .Values.additionalConfigs }} - name: CONFIG_FILE - value: '{{ if .Values.config }}{{ .Values.configMountPath }}{{ end }}{{ range .Values.additionalConfigs }}:/config/{{ tpl . $ }}.yaml{{ end }}' + value: '{{ if .Values.config }}{{ .Values.configMountPath }}{{ end }}{{ range .Values.additionalConfigs }}:/additional-configs/{{ tpl . $ }}/data.yaml{{ end }}' {{- end }} {{- range $key, $val := .Values.envFrom }}