From e703c510b3519a0e197add43655710eef97d7cd8 Mon Sep 17 00:00:00 2001 From: Jamie Wiebe Date: Wed, 23 Nov 2022 09:50:08 +0100 Subject: [PATCH] allow for arbitrary labels in chart --- charts/redisoperator/Chart.yaml | 2 +- charts/redisoperator/templates/_helpers.tpl | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/charts/redisoperator/Chart.yaml b/charts/redisoperator/Chart.yaml index f0326dd83..5dde623fa 100644 --- a/charts/redisoperator/Chart.yaml +++ b/charts/redisoperator/Chart.yaml @@ -4,7 +4,7 @@ appVersion: 1.2.2 apiVersion: v1 description: A Helm chart for the Spotahome Redis Operator name: redis-operator -version: 3.2.4 +version: 3.2.5 home: https://github.com/spotahome/redis-operator keywords: - "golang" diff --git a/charts/redisoperator/templates/_helpers.tpl b/charts/redisoperator/templates/_helpers.tpl index 49f113c09..180bcc4dd 100644 --- a/charts/redisoperator/templates/_helpers.tpl +++ b/charts/redisoperator/templates/_helpers.tpl @@ -45,6 +45,9 @@ app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} {{- end }} app.kubernetes.io/managed-by: {{ .Release.Service }} app.kubernetes.io/part-of: {{ include "chart.name" . }} +{{- range $k, $v := .Values.labels }} +{{ $k }}: {{ $v }} +{{- end }} {{- end -}} {{/* @@ -72,4 +75,4 @@ Create the name of the service account to use {{- with .Values.imageCredentials }} {{- printf "{\"auths\":{\"%s\":{\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}}}" .registry .username .password .email (printf "%s:%s" .username .password | b64enc) | b64enc }} {{- end }} -{{- end }} \ No newline at end of file +{{- end }}