diff --git a/tasks/manage_pki_realms.yml b/tasks/manage_pki_realms.yml index dec1f0b..9d057c1 100644 --- a/tasks/manage_pki_realms.yml +++ b/tasks/manage_pki_realms.yml @@ -35,6 +35,7 @@ state: directory name: /etc/cron.d mode: 0755 + when: pki_dhparams_regenerate - name: Regenerate Diffie-Hellman parameters periodically cron: @@ -44,14 +45,14 @@ user: 'root' job: 'cd {{ pki_base_path }} ; make regenerate-dhparams > /dev/null 2>&1' cron_file: 'pki-regenerate-dhparams' - when: pki_dhparams_regenerate is defined and pki_dhparams_regenerate + when: pki_dhparams_regenerate - name: Disable periodic DHparams regeneration cron: name: 'Regenerate Diffie-Hellman parameters in all PKI realms' cron_file: 'pki-regenerate-dhparams' state: 'absent' - when: pki_dhparams_regenerate is defined and not pki_dhparams_regenerate + when: not pki_dhparams_regenerate|bool - name: Create realm source directories file: