11 lines
506 B
YAML
11 lines
506 B
YAML
- name: Generate main certificate
|
|
command:
|
|
creates: /etc/letsencrypt/live/{{ hostname }}/fullchain.pem
|
|
cmd: certbot certonly --non-interactive --agree-tos --webroot -w /var/www/html -d {{ hostname }} -d www.{{ hostname }}
|
|
|
|
- name: Generate user certificates
|
|
command:
|
|
creates: "/etc/letsencrypt/live/{{ item.name }}.{{ hostname }}/fullchain.pem"
|
|
cmd: "certbot certonly --non-interactive --agree-tos --webroot -w /var/www/html -d {{ item.name }}.{{ hostname }}"
|
|
loop: "{{ users }}"
|