Adding disable support for alert service

This commit is contained in:
Philippe Caseiro 2018-06-05 16:53:11 +02:00
parent c10edef336
commit 5c16310e5d
1 changed files with 18 additions and 5 deletions

View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<creole>
<files>
<file filelist='prometheus' name='/etc/prometheus/prometheus.yml' mkdir='True' rm='True'/>
<file filelist='prometheus' name='/etc/prometheus/alertmanager.yml' mkdir='True' rm='True'/>
<file filelist='grafana' name='/etc/grafana/grafana.ini' mkdir='True' rm='True'/>
<file filelist='prometheus' name='/etc/prometheus/prometheus.yml' mkdir='True' rm='True'/>
<file filelist='alertmanager' name='/etc/prometheus/alertmanager.yml' mkdir='True' rm='True'/>
<file filelist='grafana' name='/etc/grafana/grafana.ini' mkdir='True' rm='True'/>
<service>prometheus</service>
<service>alertmanager</service>
@ -25,9 +25,12 @@
</family>
<family name='prometheus'>
<variable name='activer_grafana' type='oui/non' description="Activer le service grafana sur le serveur">
<value>oui</value>
<value>oui</value>
</variable>
<variable name='prometheusJobName' type='string' description="Nom du job ajouté au label">
<variable name='activerAlertmanager' type='oui/non' description="Activer le service d'alertes">
<value>oui</value>
</variable>
<variable name='prometheusJobName' type='string' description="Nom du job ajouté au label">
<value>prometheus</value>
</variable>
<variable name='prometheusScrapeInterval' type='string' description="Intervalle de récupération des données sur les différents noeuds">
@ -115,6 +118,8 @@
</family>
<separators>
<separator name='activer_grafana'>Services complèmentairse</separator>
<separator name='prometheusJobName'>Configuration du serveur Prometheus</separator>
<separator name='alSMTPHost'>Configuration SMTP pour l'envois des alertes</separator>
<separator name='alDefaultReceiver'>Destinatires</separator>
<separator name='alRoute'>Rêgles de distribution</separator>
@ -164,6 +169,7 @@
<condition name='disabled_if_in' source='activer_prometheus'>
<param>non</param>
<target type='family'>prometheus</target>
<target type='family'>alertes prometheus</target>
<target type='filelist'>prometheus</target>
<target type='variable'>activer_grafana</target>
</condition>
@ -172,6 +178,13 @@
<target type='family'>grafana</target>
<target type='filelist'>grafana</target>
</condition>
<condition name='disabled_if_in' source='activerAlertmanager'>
<param>non</param>
<target type='family'>alertes prometheus</target>
<target type='filelist'>alertmanager</target>
</condition>
<condition name='disabled_if_in' source='ajout_client_prometheus'>
<param>non</param>
<target type='variable'>prCli</target>