diff --git a/templates/prometheus-postgres-exporter/_deployment.tpl b/templates/prometheus-postgres-exporter/_deployment.tpl index d28b73e..d7cee1f 100644 --- a/templates/prometheus-postgres-exporter/_deployment.tpl +++ b/templates/prometheus-postgres-exporter/_deployment.tpl @@ -53,7 +53,7 @@ {{- define "prometheus-postgres-exporter.deployment.volumeMounts" -}} {{- $volumeMounts := dict "volumeMounts" (.Values.deployment.postgresExporter.volumeMounts | default (list) ) }} -{{- $volumeMounts = merge $volumeMounts (dict "volumeMounts" (list (dict "name" "config.d" "mountPath" "/etc/prometheus-postgres-exporter/config.d" ))) }} +{{- $volumeMounts = merge $volumeMounts (dict "volumeMounts" (list (dict "name" "config-d" "mountPath" "/etc/prometheus-postgres-exporter/config.d" ))) }} {{ toYaml $volumeMounts }} {{- end -}} @@ -72,7 +72,7 @@ {{- $webConfigSecretName = printf "%s-web-config" (include "prometheus-postgres-exporter.fullname" . ) }} {{- end }} -{{- $volumes = merge $volumes (dict "volumes" (list (dict "name" "config.d" "projected" (dict "defaultMode" "0444" "sources" (list (dict "secret" (dict "name" $exporterSecretName)) (dict "secret" (dict "name" $webConfigSecretName))))))) }} +{{- $volumes = merge $volumes (dict "volumes" (list (dict "name" "config-d" "projected" (dict "defaultMode" 444 "sources" (list (dict "secret" (dict "name" $exporterSecretName)) (dict "secret" (dict "name" $webConfigSecretName))))))) }} {{ toYaml $volumes }} diff --git a/unittests/deployment/deployment.yaml b/unittests/deployment/deployment.yaml index 887f97e..d562a71 100644 --- a/unittests/deployment/deployment.yaml +++ b/unittests/deployment/deployment.yaml @@ -42,13 +42,13 @@ tests: path: spec.template.spec.containers[0].volumeMounts value: - mountPath: /etc/prometheus-postgres-exporter/config.d - name: config.d + name: config-d - equal: path: spec.template.spec.volumes value: - - name: config.d + - name: config-d projected: - defaultMode: "0444" + defaultMode: 444 sources: - secret: name: prometheus-postgres-exporter-unittest-exporter-config @@ -143,13 +143,13 @@ tests: path: spec.template.spec.containers[0].volumeMounts value: - mountPath: /etc/prometheus-postgres-exporter/config.d - name: config.d + name: config-d - equal: path: spec.template.spec.volumes value: - - name: config.d + - name: config-d projected: - defaultMode: "0444" + defaultMode: 444 sources: - secret: name: exporter-config-secret @@ -165,13 +165,13 @@ tests: path: spec.template.spec.containers[0].volumeMounts value: - mountPath: /etc/prometheus-postgres-exporter/config.d - name: config.d + name: config-d - equal: path: spec.template.spec.volumes value: - - name: config.d + - name: config-d projected: - defaultMode: "0444" + defaultMode: 444 sources: - secret: name: prometheus-postgres-exporter-unittest-exporter-config