Reorganize acme vars
This commit is contained in:
parent
0164fa4660
commit
12fb975a2a
@ -34,8 +34,8 @@
|
|||||||
email_address: "rehashedsalt@cock.li"
|
email_address: "rehashedsalt@cock.li"
|
||||||
- name: Create challenge for CSR
|
- name: Create challenge for CSR
|
||||||
acme_certificate:
|
acme_certificate:
|
||||||
acme_directory: "{{ acme_directory }}"
|
acme.directory: "{{ acme.directory }}"
|
||||||
acme_version: 2
|
acme.version: 2
|
||||||
terms_agreed: yes
|
terms_agreed: yes
|
||||||
account_email: "rehashedsalt@cock.li"
|
account_email: "rehashedsalt@cock.li"
|
||||||
account_key: "/etc/pki/cert/private/account.key"
|
account_key: "/etc/pki/cert/private/account.key"
|
||||||
@ -61,19 +61,19 @@
|
|||||||
state: reloaded
|
state: reloaded
|
||||||
- name: Create well-known directory
|
- name: Create well-known directory
|
||||||
file:
|
file:
|
||||||
path: "{{ acme_webroot }}/.well-known/acme-challenge"
|
path: "{{ acme.webroot }}/.well-known/acme-challenge"
|
||||||
mode: "0755"
|
mode: "0755"
|
||||||
recurse: yes
|
recurse: yes
|
||||||
state: directory
|
state: directory
|
||||||
- name: Copy challenge files
|
- name: Copy challenge files
|
||||||
copy:
|
copy:
|
||||||
dest: "{{ acme_webroot }}/{{ com_challenge['challenge_data'][website_url]['http-01']['resource'] }}"
|
dest: "{{ acme.webroot }}/{{ com_challenge['challenge_data'][website_url]['http-01']['resource'] }}"
|
||||||
content: "{{ com_challenge['challenge_data'][website_url]['http-01']['resource_value'] }}"
|
content: "{{ com_challenge['challenge_data'][website_url]['http-01']['resource_value'] }}"
|
||||||
when: com_challenge['challenge_data']|length > 0
|
when: com_challenge['challenge_data']|length > 0
|
||||||
- name: Create certificate
|
- name: Create certificate
|
||||||
acme_certificate:
|
acme_certificate:
|
||||||
acme_directory: "{{ acme_directory }}"
|
acme.directory: "{{ acme.directory }}"
|
||||||
acme_version: 2
|
acme.version: 2
|
||||||
account_key: /etc/pki/cert/private/account.key
|
account_key: /etc/pki/cert/private/account.key
|
||||||
csr: "/etc/pki/cert/csr/{{ website_url }}.csr"
|
csr: "/etc/pki/cert/csr/{{ website_url }}.csr"
|
||||||
dest: "/etc/pki/cert/crt/{{ website_url }}.crt"
|
dest: "/etc/pki/cert/crt/{{ website_url }}.crt"
|
||||||
@ -94,7 +94,7 @@
|
|||||||
block:
|
block:
|
||||||
- name: Remove webroot
|
- name: Remove webroot
|
||||||
file:
|
file:
|
||||||
path: "{{ acme_webroot }}/.well-known/acme-challenge"
|
path: "{{ acme.webroot }}/.well-known/acme-challenge"
|
||||||
state: absent
|
state: absent
|
||||||
- name: Remove temporary config
|
- name: Remove temporary config
|
||||||
file:
|
file:
|
||||||
|
Loading…
Reference in New Issue
Block a user