From 119e1343739acea0d7e28d1d63be84e843a45501 Mon Sep 17 00:00:00 2001 From: Mathieu Trossevin Date: Fri, 19 Jun 2020 13:29:30 +0200 Subject: [PATCH] [Cleanup] php and postfix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Comparison with litteral True and False ( `var == False` ⇔ `not var` or `var is boolean and var` or ` var is sameas False` should there be a need to check if it is really a boolean that is False and not only something evaluationg to False) --- php/tasks/main.yml | 3 ++- postfix/meta/main.yml | 10 +++++----- postfix/tasks/main.yml | 4 ++-- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/php/tasks/main.yml b/php/tasks/main.yml index 2fd1a250..514c0202 100644 --- a/php/tasks/main.yml +++ b/php/tasks/main.yml @@ -1,6 +1,7 @@ --- -- fail: +- name: Check for compatibility + fail: msg: only compatible with Debian >= 8 when: - ansible_distribution != "Debian" or ansible_distribution_major_version is version('8', '<') diff --git a/postfix/meta/main.yml b/postfix/meta/main.yml index fe59228a..91cd3862 100644 --- a/postfix/meta/main.yml +++ b/postfix/meta/main.yml @@ -14,8 +14,8 @@ galaxy_info: - jessie dependencies: - - { role: evolix/ldap, ldap_schema: 'cn4evolix.ldif', when: postfix_packmail == True } - - { role: evolix/spamassasin, when: postfix_packmail == True } - - { role: evolix/clamav, when: postfix_packmail == True } - - { role: evolix/opendkim, when: postfix_packmail == True } - - { role: evolix/dovecot, when: postfix_packmail == True } + - { role: evolix/ldap, ldap_schema: 'cn4evolix.ldif', when: postfix_packmail } + - { role: evolix/spamassasin, when: postfix_packmail } + - { role: evolix/clamav, when: postfix_packmail } + - { role: evolix/opendkim, when: postfix_packmail } + - { role: evolix/dovecot, when: postfix_packmail } diff --git a/postfix/tasks/main.yml b/postfix/tasks/main.yml index 0e0fff2d..5d7d4958 100644 --- a/postfix/tasks/main.yml +++ b/postfix/tasks/main.yml @@ -3,10 +3,10 @@ - include: common.yml - include: minimal.yml - when: postfix_packmail == False + when: not postfix_packmail - include: packmail.yml - when: postfix_packmail == True + when: postfix_packmail - include: slow_transport.yml when: postfix_slow_transport_include