We need empty {} to evaluate alerts
For some alerts we use reclass to get variables (ex. threshold). To get those reclass variables we use `prometheus_server` dict, which on nodes without prometheus class is None. We need to provide at least empty dict in that case. Change-Id: Ic1f2c1776c4852701dcf9f8a76f933926b2d9aec
This commit is contained in:
parent
45d0bb8fe7
commit
9b3d774430
1 changed files with 4 additions and 0 deletions
|
@ -1,5 +1,9 @@
|
||||||
{% set server = salt['grains.filter_by']({
|
{% set server = salt['grains.filter_by']({
|
||||||
|
'default': {
|
||||||
|
},
|
||||||
}, merge=salt['pillar.get']('prometheus:server')) %}
|
}, merge=salt['pillar.get']('prometheus:server')) %}
|
||||||
|
|
||||||
{% set alertmanager = salt['grains.filter_by']({
|
{% set alertmanager = salt['grains.filter_by']({
|
||||||
|
'default': {
|
||||||
|
},
|
||||||
}, merge=salt['pillar.get']('prometheus:alertmanager')) %}
|
}, merge=salt['pillar.get']('prometheus:alertmanager')) %}
|
||||||
|
|
Loading…
Reference in a new issue