Skip to content

Commit

Permalink
[DO NOT MERGE] More debugging.
Browse files Browse the repository at this point in the history
  • Loading branch information
felixfontein committed May 20, 2024
1 parent 410bf46 commit f9c2233
Showing 1 changed file with 43 additions and 1 deletion.
44 changes: 43 additions & 1 deletion tests/integration/targets/acme_certificate_order/tasks/impl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,44 @@
- validate_1 is changed
- validate_1.account_uri == account.account_uri

- name: Get order information
- name: Get order information (1/2)
acme_certificate_order_info:
acme_directory: https://{{ acme_host }}:14000/dir
acme_version: 2
validate_certs: false
account_key_src: "{{ remote_tmp_dir }}/accountkey.pem"
select_crypto_backend: "{{ select_crypto_backend }}"
order_uri: "{{ order.order_uri }}"
register: order_info_2

- name: Get authz
acme_inspect:
acme_directory: https://{{ acme_host }}:14000/dir
acme_version: 2
validate_certs: false
account_key_src: "{{ remote_tmp_dir }}/accountkey.pem"
account_uri: "{{ order_info_2.account_uri }}"
select_crypto_backend: "{{ select_crypto_backend }}"
method: get
url: >-
{{ order_info_2.authorizations_by_identifier['dns:' ~ domain_name].uri }}
- name: Get http-01 challenge
acme_inspect:
acme_directory: https://{{ acme_host }}:14000/dir
acme_version: 2
validate_certs: false
account_key_src: "{{ remote_tmp_dir }}/accountkey.pem"
account_uri: "{{ order_info_2.account_uri }}"
select_crypto_backend: "{{ select_crypto_backend }}"
method: get
url: >-
{{ order_info_2.authorizations_by_identifier['dns:' ~ domain_name].challenges | selectattr('type', 'equalto', 'http-01') | map(attribute='url') | first }}
- pause:
seconds: 1

- name: Get order information (2/2)
acme_certificate_order_info:
acme_directory: https://{{ acme_host }}:14000/dir
acme_version: 2
Expand All @@ -160,6 +197,11 @@
debug:
var: order_info_2

- debug:
var: order_info_2.authorizations_by_identifier['dns:' ~ domain_name].challenges | selectattr('type', 'equalto', 'http-01') | map(attribute='status') | first | default('not there')
- debug:
var: order_info_2.authorizations_by_identifier['dns:' ~ domain_name].challenges | selectattr('type', 'equalto', 'dns-01') | map(attribute='status') | first | default('not there')

- name: Check order information
assert:
that:
Expand Down

0 comments on commit f9c2233

Please sign in to comment.