mattez02-infra/tasks/deployer.yml
Christer Warén d4796323d8 Tasks Add
2024-12-16 15:00:59 +02:00

26 lines
644 B
YAML

---
- name: "Deployer - Certbot - Renew Certificates"
command: "certbot renew --config-dir ~/data/letsencrypt/config --logs-dir ~/data/letsencrypt/logs --work-dir ~/data/letsencrypt/work"
register: task
changed_when: task.stdout.find("No renewals were attempted.") == -1
tags:
- certbot
- tls
- name: "Deployer - Certbot - Copy Certificates"
copy:
src: "~/data/letsencrypt/live/{{ cert }}/"
dest: "~/data/certificates/{{ cert }}/"
follow: true
loop: "{{ certs }}"
loop_control:
label: "{{ cert }}"
loop_var: "cert"
vars:
certs:
- arcadiamc
register: task
tags:
- certbot
- tls