diff --git a/CHANGELOG.md b/CHANGELOG.md index 8eebf5c..d1dca5f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,3 +10,4 @@ * Manage memory mode. * Define some vars to manage master and slaves configuration. * Combine 4 vars to generate Netdata configuration. +* Slaves alarms can be disable, the master will not send alarms. diff --git a/README.md b/README.md index 59ca59b..0413ea5 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,7 @@ A role to manage Netdata installation and configuration. * **netdata__master_api_key** : The API key to authenticate slaves [default : `''`]. * **netdata__master_history** : The number of entries in the database per hosts [default : `3600`]. * **netdata__master_memory_mode** : The memory mode to be used for all hosts using this API key [default : `ram`]. +* **netdata__master_health_alarm** : Shall the master send alarms for hosts using the API key [default : `auto`]. ## Example Playbook diff --git a/defaults/main.yml b/defaults/main.yml index d143218..8416f50 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -188,7 +188,6 @@ netdata__slave_reconnect: '5' # # If node should receive metrics from other nodes. Possible options : # -# # ``False`` # Default. # @@ -219,5 +218,20 @@ netdata__master_history: '3600' netdata__master_memory_mode: 'ram' # ]]] +# .. envvar:: netdata__master_health_alarm [[[. +# +# Shall the master send alarms for hosts using the API key. Possible options : +# +# ``auto`` +# Default. Enable alarms, only when the sending Netdata is connected. +# +# ``yes`` +# Enable alarms. +# +# ``no`` +# Do not enable alarms +netdata__master_health_alarm: 'auto' + + # ]]] # ]]] diff --git a/templates/etc/netdata/stream.conf.j2 b/templates/etc/netdata/stream.conf.j2 index f04d660..732d453 100644 --- a/templates/etc/netdata/stream.conf.j2 +++ b/templates/etc/netdata/stream.conf.j2 @@ -105,7 +105,7 @@ # auto enable alarms, only when the sending netdata is connected # You can also set it per host, below. # The default is the same as to netdata.conf - health enabled by default = auto + health enabled by default = {{ netdata__master_health_alarm }} # postpone alarms for a short period after the sender is connected default postpone alarms on connect seconds = 60