diff --git a/letsencrypt-acmetool-client/tasks/main.yml b/letsencrypt-acmetool-client/tasks/main.yml index ec55cf99..e6961cb2 100644 --- a/letsencrypt-acmetool-client/tasks/main.yml +++ b/letsencrypt-acmetool-client/tasks/main.yml @@ -79,6 +79,7 @@ become_user: '{{ letsencrypt_acme_user }}' template: src=cert-requirements.j2 dest={{ letsencrypt_acme_certsconf_dir }}/{{ ansible_fqdn }} mode=0644 when: letsencrypt_acme_install + register: letsencrypt_new_desired_file tags: letsencrypt - name: Set the cap_net_bind_service capability to the acmetool binary when we use it in listener mode @@ -132,7 +133,7 @@ become: True become_user: '{{ letsencrypt_acme_user }}' shell: '/usr/local/bin/acme-cert-request > {{ letsencrypt_acme_log_dir }}/acme-init.log 2>&1' - when: letsencrypt_acme_install + when: ( letsencrypt_new_desired_file | changed ) ignore_errors: True tags: letsencrypt