From 399585f4e7542f1fcc1a51ed9868def0796f93ad Mon Sep 17 00:00:00 2001 From: Alan Orth Date: Sun, 11 Sep 2022 08:39:59 +0300 Subject: [PATCH] roles: don't compare literal true and false I changed these yesterday when editing the truthy values, but acco- rding to ansible-link we can just rely on them being true or false without comparing. --- roles/nginx/tasks/wordpress.yml | 4 ++-- roles/php-fpm/tasks/Debian_10.yml | 2 +- roles/php-fpm/tasks/Ubuntu_20.04.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/roles/nginx/tasks/wordpress.yml b/roles/nginx/tasks/wordpress.yml index 739759b..0f376b3 100644 --- a/roles/nginx/tasks/wordpress.yml +++ b/roles/nginx/tasks/wordpress.yml @@ -5,14 +5,14 @@ ansible.builtin.git: repo=https://github.com/WordPress/WordPress.git dest={{ nginx_root_prefix }}/{{ item.domain_name }}/wordpress version={{ item.wordpress_version }} depth=1 force=true when: - item.has_wordpress is defined - - item.has_wordpress == true + - item.has_wordpress loop: "{{ nginx_vhosts }}" - name: Fix WordPress directory permissions ansible.builtin.file: path={{ nginx_root_prefix }}/{{ item.domain_name }} state=directory owner=nginx group=nginx recurse=true when: - item.has_wordpress is defined - - item.has_wordpress == true + - item.has_wordpress loop: "{{ nginx_vhosts }}" tags: wordpress diff --git a/roles/php-fpm/tasks/Debian_10.yml b/roles/php-fpm/tasks/Debian_10.yml index ec8db40..d19aca4 100644 --- a/roles/php-fpm/tasks/Debian_10.yml +++ b/roles/php-fpm/tasks/Debian_10.yml @@ -30,6 +30,6 @@ notify: reload php7.3-fpm tags: php-fpm - when: install_php == true + when: install_php # vim: set ts=2 sw=2: diff --git a/roles/php-fpm/tasks/Ubuntu_20.04.yml b/roles/php-fpm/tasks/Ubuntu_20.04.yml index 79a9767..5195978 100644 --- a/roles/php-fpm/tasks/Ubuntu_20.04.yml +++ b/roles/php-fpm/tasks/Ubuntu_20.04.yml @@ -31,6 +31,6 @@ notify: reload php7.4-fpm tags: php-fpm - when: install_php == true + when: install_php # vim: set ts=2 sw=2: