From 523e7ab69ed0f88bdd53c013f5c08b91fb5ced4a Mon Sep 17 00:00:00 2001
From: jurgenhaas <juergen@paragon-es.de>
Date: Sun, 1 Apr 2018 09:54:54 +0200
Subject: [PATCH] Remove options that prevent clear notifications

---
 tasks/configure.yml | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/tasks/configure.yml b/tasks/configure.yml
index e1452ba..cf210ca 100644
--- a/tasks/configure.yml
+++ b/tasks/configure.yml
@@ -49,6 +49,17 @@
   notify:
     - "Restart NetData"
 
+- name: "Get a list of all health config files"
+  shell: 'ls /etc/netdata/health.d/*.conf -1'
+  register: health_list
+
+- name: "Remove all options that prevent clear notifications"
+  lineinfile:
+    path: '{{ item }}'
+    state: absent
+    regexp: 'no-clear-notification'
+  with_items: '{{ health_list.stdout_lines }}'
+
 - name: "Patch Startup Script"
   lineinfile:
     dest: '/etc/init.d/netdata'
-- 
GitLab