diff --git a/charts/kube-prometheus-stack/Chart.yaml b/charts/kube-prometheus-stack/Chart.yaml index a345a7367b5d..137802290b7d 100644 --- a/charts/kube-prometheus-stack/Chart.yaml +++ b/charts/kube-prometheus-stack/Chart.yaml @@ -23,7 +23,7 @@ name: kube-prometheus-stack sources: - https://github.com/prometheus-community/helm-charts - https://github.com/prometheus-operator/kube-prometheus -version: 56.6.1 +version: 56.6.2 appVersion: v0.71.2 kubeVersion: ">=1.19.0-0" home: https://github.com/prometheus-operator/kube-prometheus diff --git a/charts/kube-prometheus-stack/templates/_helpers.tpl b/charts/kube-prometheus-stack/templates/_helpers.tpl index fb5bac34e1c4..aa0ed4c73623 100644 --- a/charts/kube-prometheus-stack/templates/_helpers.tpl +++ b/charts/kube-prometheus-stack/templates/_helpers.tpl @@ -24,10 +24,15 @@ The longest name that gets created adds and extra 37 characters, so truncation s {{- end -}} {{- end -}} -{{/* Fullname suffixed with operator */}} +{{/* Fullname suffixed with -operator */}} +{{/* Adding 9 to 26 truncation of kube-prometheus-stack.fullname */}} {{- define "kube-prometheus-stack.operator.fullname" -}} +{{- if .Values.prometheusOperator.fullnameOverride -}} +{{- .Values.prometheusOperator.fullnameOverride | trunc 35 | trimSuffix "-" -}} +{{- else -}} {{- printf "%s-operator" (include "kube-prometheus-stack.fullname" .) -}} {{- end }} +{{- end }} {{/* Prometheus custom resource instance name */}} {{- define "kube-prometheus-stack.prometheus.crname" -}} diff --git a/charts/kube-prometheus-stack/values.yaml b/charts/kube-prometheus-stack/values.yaml index 0502300c5fa7..529f5d048484 100644 --- a/charts/kube-prometheus-stack/values.yaml +++ b/charts/kube-prometheus-stack/values.yaml @@ -2073,6 +2073,9 @@ prometheus-node-exporter: prometheusOperator: enabled: true + ## Use '{{ template "kube-prometheus-stack.fullname" . }}-operator' by default + fullnameOverride: "" + ## Number of old replicasets to retain ## ## The default value is 10, 0 will garbage-collect old replicasets ## revisionHistoryLimit: 10