From 1ce9dca14cc9674169f4c1dc4aef891f28ba3f71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20B=C3=A4hler?= Date: Thu, 10 Jul 2025 10:38:11 +0200 Subject: [PATCH] fix(helm): correct values scope for dashboards (#1537) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Oliver Bähler --- charts/capsule/templates/dashboards.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/charts/capsule/templates/dashboards.yaml b/charts/capsule/templates/dashboards.yaml index 14d76532..b074d7fc 100644 --- a/charts/capsule/templates/dashboards.yaml +++ b/charts/capsule/templates/dashboards.yaml @@ -14,7 +14,7 @@ metadata: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "capsule.labels" . | nindent 4 }} + {{- include "capsule.labels" $ | nindent 4 }} {{- with $.Values.monitoring.dashboards.labels }} {{- toYaml . | nindent 4 }} {{- end }} @@ -27,20 +27,20 @@ data: apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard metadata: - name: {{ include "capsule.fullname" . }}-{{ $path | base | trimSuffix "-dashboard.json" | regexFind "[^_]+$" }} + name: {{ include "capsule.fullname" $ }}-{{ $path | base | trimSuffix "-dashboard.json" | regexFind "[^_]+$" }} namespace: {{ default $.Release.Namespace $.Values.monitoring.dashboards.namespace | quote }} annotations: {{- with $.Values.monitoring.dashboards.annotations }} {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "capsule.labels" . | nindent 4 }} + {{- include "capsule.labels" $ | nindent 4 }} {{- with $.Values.monitoring.dashboards.labels }} {{- toYaml . | nindent 4 }} {{- end }} spec: configMapRef: - name: {{ include "capsule.fullname" . }}-{{ $path | base | trimSuffix "-dashboard.json" | regexFind "[^_]+$" }}-dashboard + name: {{ include "capsule.fullname" $ }}-{{ $path | base | trimSuffix "-dashboard.json" | regexFind "[^_]+$" }}-dashboard key: {{ base $path }} {{- with (omit $.Values.monitoring.dashboards.operator "enabled") }} {{- toYaml . | nindent 2 }}