sendmail: Add automatic ca certificate updates

This commit is contained in:
Timo Makinen 2024-03-12 18:41:50 +00:00
parent 778f8e99d7
commit 7c9727c6a6
4 changed files with 50 additions and 1 deletions

View file

@ -16,6 +16,22 @@
owner: root
group: "{{ ansible_wheel }}"
- name: Add script to update root certs
ansible.builtin.copy:
dest: /usr/local/sbin/update-sendmail-certs
src: update-sendmail-certs.sh
mode: "0755"
owner: root
group: "{{ ansible_wheel }}"
notify: Update sendmail root certs
- name: Add cronjob to update root certs
ansible.builtin.cron:
name: update-sendmail-certs
job: /usr/local/sbin/update-sendmail-certs
hour: "05"
minute: "30"
- name: Copy private key
ansible.builtin.copy:
dest: "{{ tls_private }}/{{ mail_server }}.key"