diff --git a/lib/ansible/modules/crypto/acme/acme_certificate.py b/lib/ansible/modules/crypto/acme/acme_certificate.py index ff36082c10..cf6b4e0b69 100644 --- a/lib/ansible/modules/crypto/acme/acme_certificate.py +++ b/lib/ansible/modules/crypto/acme/acme_certificate.py @@ -247,7 +247,7 @@ EXAMPLES = R''' # # Note: item.value is a list of TXT entries, and route53 # # requires every entry to be enclosed in quotes # value: "{{ item.value | map('regex_replace', '^(.*)$', '\'\\1\'' ) | list }}" -# with_dict: sample_com_challenge.challenge_data_dns +# loop: "{{ sample_com_challenge.challenge_data_dns | dictsort }}" # when: sample_com_challenge is changed - name: Let the challenge be validated and retrieve the cert and intermediate certificate diff --git a/lib/ansible/modules/crypto/acme/acme_challenge_cert_helper.py b/lib/ansible/modules/crypto/acme/acme_challenge_cert_helper.py index 0f41b3514e..9ef0570341 100644 --- a/lib/ansible/modules/crypto/acme/acme_challenge_cert_helper.py +++ b/lib/ansible/modules/crypto/acme/acme_challenge_cert_helper.py @@ -64,7 +64,7 @@ EXAMPLES = ''' challenge: tls-alpn-01 challenge_data: "{{ item.value['tls-alpn-01'] }}" private_key_src: /etc/pki/cert/key/sample.com.key - with_items: "{{ sample_com_challenge.challenge_data }}" + loop: "{{ sample_com_challenge.challenge_data | dictsort }}" register: sample_com_challenge_certs - name: Install challenge certificates @@ -81,7 +81,7 @@ EXAMPLES = ''' challenge_certificate: "{{ item.challenge_certificate }}" regular_certificate: "{{ item.regular_certificate }}" private_key: /etc/pki/cert/key/sample.com.key - with_items: "{{ sample_com_challenge_certs.results }}" + loop: "{{ sample_com_challenge_certs.results }}" - name: Create certificate for a given CSR for sample.com acme_certificate: