From 82de005fdfb5aaccdbd917e74ba8603e898b84c0 Mon Sep 17 00:00:00 2001 From: Mark Meijerman Date: Tue, 11 Jun 2019 08:08:37 +0200 Subject: [PATCH] Resolve ansible deprecation warnings Ansible version 2.8.0 yields these type of deprecation warnings: ``` TASK [HanXHX.mysql : APT_KEY | Install Percona key] **************************** [DEPRECATION WARNING]: evaluating mariadb_use_percona_apt as a bare variable, this behaviour will go away and you might need to add |bool to the expression in the future. Also see CONDITIONAL_BARE_VARS configuration toggle.. This feature will be removed in version 2.12. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg. ``` --- tasks/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasks/main.yml b/tasks/main.yml index 680aeda..04c2197 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -2,10 +2,10 @@ - import_tasks: include-vars.yml - import_tasks: install-with-package.yml - when: not certbot_install_from_source + when: not certbot_install_from_source | bool - import_tasks: install-from-source.yml - when: certbot_install_from_source + when: certbot_install_from_source | bool - include_tasks: create-cert-standalone.yml with_items: "{{ certbot_certs }}" @@ -16,4 +16,4 @@ loop_var: cert_item - import_tasks: renew-cron.yml - when: certbot_auto_renew + when: certbot_auto_renew | bool