This commit is contained in:
Amarpreet Minhas 2022-03-26 18:07:03 -04:00
parent 6abe601862
commit a2657b7133

View file

@ -100,12 +100,26 @@
mode: 0700
loop: "{{ lego_certs }}"
- name: set cron env to bash
cron:
name: SHELL
env: True
job: /bin/bash
user: lego
- name: set cron env to bash
cron:
name: SHELL
env: True
job: /bin/bash
user: root
- name: create renewal crontabs
cron:
name: "{{ item.name }} renewal"
hour: "4"
user: lego
job: 'source /etc/default/lego && /usr/local/bin/lego --pem --path {{ lego_path }} --email {{ lego_email_address }} --dns {{ item.dns }} --domains "{{ item.domain }}" renew --days 45'
job: 'source /etc/default/lego && /usr/local/bin/lego --pem --path {{ lego_path }} --email {{ lego_email_address }} --dns {{ item.dns }} --domains "{{ item.domain }}" renew --days 30'
loop: "{{ lego_certs }}"
- name: create haproxy reload crontab