Add extensible command line flags to Alertmanager
Alertmanager is configured similarly to Prometheus. This change brings the utils.command_line_flags template from the osh-infra prometheus chart to Alertmanager, allowing these flags to be configured in Values.yaml Change-Id: Ieca94c09881bc52b62500efa4c6f8730b9208d3b
This commit is contained in:
parent
4665fdad03
commit
2bdf4f8239
@ -15,7 +15,7 @@ apiVersion: v1
|
|||||||
appVersion: v0.20.0
|
appVersion: v0.20.0
|
||||||
description: OpenStack-Helm Alertmanager for Prometheus
|
description: OpenStack-Helm Alertmanager for Prometheus
|
||||||
name: prometheus-alertmanager
|
name: prometheus-alertmanager
|
||||||
version: 0.1.1
|
version: 0.1.2
|
||||||
home: https://prometheus.io/docs/alerting/alertmanager/
|
home: https://prometheus.io/docs/alerting/alertmanager/
|
||||||
sources:
|
sources:
|
||||||
- https://github.com/prometheus/alertmanager
|
- https://github.com/prometheus/alertmanager
|
||||||
|
@ -20,8 +20,10 @@ COMMAND="${@:-start}"
|
|||||||
function start () {
|
function start () {
|
||||||
exec /bin/alertmanager \
|
exec /bin/alertmanager \
|
||||||
--config.file=/etc/alertmanager/config.yml \
|
--config.file=/etc/alertmanager/config.yml \
|
||||||
--storage.path={{ .Values.conf.command_flags.alertmanager.storage.path }} \
|
{{- range $flag, $value := .Values.conf.command_flags.alertmanager }}
|
||||||
--cluster.listen-address={{ .Values.conf.command_flags.alertmanager.cluster.listen_address }} \
|
{{- $flag := $flag | replace "_" "-" }}
|
||||||
|
{{ printf "--%s=%s" $flag $value | indent 4 }} \
|
||||||
|
{{- end }}
|
||||||
$(generate_peers)
|
$(generate_peers)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -250,10 +250,8 @@ network_policy:
|
|||||||
conf:
|
conf:
|
||||||
command_flags:
|
command_flags:
|
||||||
alertmanager:
|
alertmanager:
|
||||||
storage:
|
storage.path: /var/lib/alertmanager/data
|
||||||
path: /var/lib/alertmanager/data
|
cluster.listen_address: "0.0.0.0:9094"
|
||||||
cluster:
|
|
||||||
listen_address: "0.0.0.0:9094"
|
|
||||||
snmpnotifier:
|
snmpnotifier:
|
||||||
alert_default_severity: crititcal
|
alert_default_severity: crititcal
|
||||||
alert_severities: "critical,warning,info,page"
|
alert_severities: "critical,warning,info,page"
|
||||||
|
Loading…
Reference in New Issue
Block a user