diff --git a/charts/victoria-metrics-k8s-stack/CHANGELOG.md b/charts/victoria-metrics-k8s-stack/CHANGELOG.md index 32843eff0..d779d40fe 100644 --- a/charts/victoria-metrics-k8s-stack/CHANGELOG.md +++ b/charts/victoria-metrics-k8s-stack/CHANGELOG.md @@ -3,6 +3,7 @@ - Added VMAuth to k8s stack. See [this issue](https://github.com/VictoriaMetrics/helm-charts/issues/829) - Fixed ETCD dashboard - Use path prefix from args as a default path prefix for ingress. Related [issue](https://github.com/VictoriaMetrics/helm-charts/issues/1260) +- Allow using vmalert without notifiers configuration. Note that it is required to use `.vmalert.spec.extraArgs["notifiers.blackhole"]: true` in order to start vmalert with a blackhole configuration. ## 0.25.16 diff --git a/charts/victoria-metrics-k8s-stack/Chart.yaml b/charts/victoria-metrics-k8s-stack/Chart.yaml index ccd47be1b..8e0621037 100644 --- a/charts/victoria-metrics-k8s-stack/Chart.yaml +++ b/charts/victoria-metrics-k8s-stack/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: victoria-metrics-k8s-stack description: Kubernetes monitoring on VictoriaMetrics stack. Includes VictoriaMetrics Operator, Grafana dashboards, ServiceScrapes and VMRules type: application -version: 0.25.16 +version: 0.25.17 appVersion: v1.102.1 sources: - https://github.com/VictoriaMetrics/helm-charts diff --git a/charts/victoria-metrics-k8s-stack/templates/_helpers.tpl b/charts/victoria-metrics-k8s-stack/templates/_helpers.tpl index f386f57fe..4429e725e 100644 --- a/charts/victoria-metrics-k8s-stack/templates/_helpers.tpl +++ b/charts/victoria-metrics-k8s-stack/templates/_helpers.tpl @@ -256,8 +256,8 @@ If release name contains chart name it will be used as a full name. {{- $_ := set $vmAlertRemotes "notifiers" . }} {{- end }} {{- $spec := deepCopy (omit $Values.vmalert.spec "notifiers") | mergeOverwrite $vmAlertRemotes | mergeOverwrite $vmAlertTemplates | mergeOverwrite $spec }} - {{- if not (or (hasKey $spec "notifier") (hasKey $spec "notifiers") (hasKey $spec "notifierConfigRef")) }} - {{- fail "`notifier`, `notifiers` or `notifierConfigRef` should be set for vmalert"}} + {{- if not (or (hasKey $spec "notifier") (hasKey $spec "notifiers") (hasKey $spec "notifierConfigRef") (hasKey $spec.extraArgs "notifier.blackhole")) }} + {{- fail "Neither `notifier`, `notifiers` nor `notifierConfigRef` is set for vmalert. If it's intentionally please consider setting `.vmalert.spec.extraArgs.['notifier.blackhole']` to `'true'`"}} {{- end }} {{- tpl (deepCopy (omit $Values.vmalert.spec "notifiers") | mergeOverwrite $vmAlertRemotes | mergeOverwrite $vmAlertTemplates | mergeOverwrite $spec | toYaml) . -}} {{- end }}