blob: 7fa71792a32209fe3088e67491ea7e894380f9f8 [file] [log] [blame]
{%- if pillar.salt is defined %}
{%- if pillar.salt.get('master', {}).get('enabled', False) or pillar.salt.get('minion', {}).get('enabled', False) %}
server:
alert:
{%- if pillar.salt.get('master', {}).get('enabled', False) %}
{%- raw %}
SaltMasterServiceDown:
if: >-
procstat_running{process_name="salt-master"} == 0
labels:
severity: critical
service: salt
annotations:
summary: "Salt-master service is down"
description: "The salt-master service on the {{ $labels.host }} node is down."
{%- endraw %}
{%- endif %}
{%- if pillar.salt.get('minion', {}).get('enabled', False) %}
{%- raw %}
SaltMinionServiceDown:
if: >-
procstat_running{process_name="salt-minion"} == 0
labels:
severity: critical
service: salt
annotations:
summary: "Salt-minion service is down"
description: "The salt-minion service on the {{ $labels.host }} node is down."
{%- endraw %}
{%- endif %}
{%- endif %}
{%- endif %}