Closed avalor1 closed 1 year ago
There's now on all but one task the same when-condition challenge['challenge_data'][item] is defined
set.
What's with the last task? And could we move the conditions to one central place? Maybe to the include?
- name: Create challenge
ansible.builtin.include_tasks: create-challenge.yml
One task right in the middle ("Let the challenge be validated...") does not have this condition thus we cannot use a block or move it to the include. This task does not need this condition as this makes it possible to retrieve a cert when it was already validated in another run but the challenge did not change during the current run.
If certificate is not due for renewal there is no challenge data but it still tried to create txt records and fails.
This PR fixes this behaviour.