From 9875771d999cb00334e3c025a8c151c2142e9af0 Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Mon, 2 Dec 2024 14:53:03 +1100 Subject: [PATCH] [prometheus-blackbox-exporter] Remove toYaml from extraManifests template Signed-off-by: Andrew Titmuss --- charts/prometheus-blackbox-exporter/Chart.yaml | 2 +- charts/prometheus-blackbox-exporter/README.md | 4 ++++ .../prometheus-blackbox-exporter/ci/extra-manifests.yaml | 8 ++++++++ .../templates/extra-manifests.yaml | 2 +- charts/prometheus-blackbox-exporter/values.yaml | 3 ++- 5 files changed, 16 insertions(+), 3 deletions(-) create mode 100644 charts/prometheus-blackbox-exporter/ci/extra-manifests.yaml diff --git a/charts/prometheus-blackbox-exporter/Chart.yaml b/charts/prometheus-blackbox-exporter/Chart.yaml index 7bf5ac1b4777..5d7ed9d47ef8 100644 --- a/charts/prometheus-blackbox-exporter/Chart.yaml +++ b/charts/prometheus-blackbox-exporter/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v2 description: Prometheus Blackbox Exporter name: prometheus-blackbox-exporter -version: 9.1.0 +version: 10.0.0 appVersion: v0.25.0 kubeVersion: ">=1.21.0-0" home: https://github.com/prometheus/blackbox_exporter diff --git a/charts/prometheus-blackbox-exporter/README.md b/charts/prometheus-blackbox-exporter/README.md index 99e9298648e1..28ebc03142b5 100644 --- a/charts/prometheus-blackbox-exporter/README.md +++ b/charts/prometheus-blackbox-exporter/README.md @@ -48,6 +48,10 @@ helm upgrade [RELEASE_NAME] [CHART] --install _See [helm upgrade](https://helm.sh/docs/helm/helm_upgrade/) for command documentation._ +### To 10.0.0 + +This version changes `extraManifests` to be a string array input, allowing things like templating the `labels` field of an object. + ### To 9.0.0 This version remove pod security policy as it is deprecated. diff --git a/charts/prometheus-blackbox-exporter/ci/extra-manifests.yaml b/charts/prometheus-blackbox-exporter/ci/extra-manifests.yaml new file mode 100644 index 000000000000..1e592024ff77 --- /dev/null +++ b/charts/prometheus-blackbox-exporter/ci/extra-manifests.yaml @@ -0,0 +1,8 @@ +extraManifests: +- | + apiVersion: v1 + kind: ConfigMap + metadata: + name: {{ include "prometheus-blackbox-exporter.fullname" . }} + data: + extra-data: value2 \ No newline at end of file diff --git a/charts/prometheus-blackbox-exporter/templates/extra-manifests.yaml b/charts/prometheus-blackbox-exporter/templates/extra-manifests.yaml index 567f7bf32971..2b21b710621f 100644 --- a/charts/prometheus-blackbox-exporter/templates/extra-manifests.yaml +++ b/charts/prometheus-blackbox-exporter/templates/extra-manifests.yaml @@ -1,4 +1,4 @@ {{ range .Values.extraManifests }} --- -{{ tpl (toYaml .) $ }} +{{ tpl . $ }} {{ end }} diff --git a/charts/prometheus-blackbox-exporter/values.yaml b/charts/prometheus-blackbox-exporter/values.yaml index 564d90f1e1f7..91980e0051b2 100644 --- a/charts/prometheus-blackbox-exporter/values.yaml +++ b/charts/prometheus-blackbox-exporter/values.yaml @@ -387,7 +387,8 @@ dnsConfig: # Extra manifests to deploy as an array extraManifests: [] - # - apiVersion: v1 + # - | + # apiVersion: v1 # kind: ConfigMap # metadata: # labels: