netz39-infra-ansible/roles/dd24-dyndns-cron/tasks/main.yml
Stefan Haun 20942f8f4b Add role dd24-dyndns-cron
Setup cron job to call curl for DynDNS update
2022-08-04 17:03:09 +02:00

18 lines
450 B
YAML

---
- name: Make sure cron and curl are installed
apt:
name:
- cron
- curl
state: present
- name: Setup cron file for DD24 updates
ansible.builtin.template:
src: "templates/dd24-dyndns.cron.j2"
dest: "/etc/cron.d/dd24-dyndns"
owner: root
group: root
mode: "0644"
notify: reload cron
# There is ansible.builtin.cron, but this makes configuration much
# more complicated, so we stick to the template.