0ec41f2092
This patch extends the configuration task for prometheus to allow the operator to pass a(set) of prometheus alert rules files, that will be used by alertmanager to produce alerts. This functionality is only enabled when the prometheus-alertmanager service is enabled. Change-Id: I882759c3774f43640631c1058f8a9cb24e7a60d2 Closes-Bug: #1776529 Signed-off-by: Jorge Niedbalski <jorge.niedbalski@linaro.org>
33 lines
1022 B
Django/Jinja
33 lines
1022 B
Django/Jinja
{
|
|
"command": "/opt/prometheus/prometheus -config.file /etc/prometheus/prometheus.yml -web.listen-address {{ api_interface_address }}:{{ prometheus_port }} -log.format logger:stdout -storage.local.path /var/lib/prometheus",
|
|
"config_files": [
|
|
{
|
|
"source": "{{ container_config_directory }}/prometheus.yml",
|
|
"dest": "/etc/prometheus/prometheus.yml",
|
|
"owner": "prometheus",
|
|
"perm": "0600"
|
|
}
|
|
{% if enable_prometheus_alertmanager %}
|
|
,{
|
|
"source": "{{ container_config_directory }}/*.rules",
|
|
"dest": "/etc/prometheus/",
|
|
"optional": true,
|
|
"owner": "prometheus",
|
|
"perm": "0600"
|
|
}
|
|
{% endif %}
|
|
],
|
|
"permissions": [
|
|
{
|
|
"path": "/data",
|
|
"owner": "prometheus:kolla",
|
|
"recurse": true
|
|
},
|
|
{
|
|
"path": "/var/log/kolla/prometheus",
|
|
"owner": "prometheus:kolla",
|
|
"recurse": true
|
|
}
|
|
]
|
|
}
|