From b0c2476c07846001fe9758db2be3c20b7fd0db8e Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Mon, 4 Nov 2013 05:32:27 +0100 Subject: Don't start daemons when there is a triggered handler. This is pointless since the service will be restarted anyway. --- roles/common/tasks/fail2ban.yml | 2 ++ 1 file changed, 2 insertions(+) (limited to 'roles/common/tasks/fail2ban.yml') diff --git a/roles/common/tasks/fail2ban.yml b/roles/common/tasks/fail2ban.yml index 3c13d8c..d5007b9 100644 --- a/roles/common/tasks/fail2ban.yml +++ b/roles/common/tasks/fail2ban.yml @@ -6,10 +6,12 @@ dest=/etc/fail2ban/jail.local owner=root group=root mode=0644 + register: r notify: - Restart fail2ban - name: Start fail2ban service: name=fail2ban state=started + when: not r.changed - meta: flush_handlers -- cgit v1.2.3