homeserver/playbooks/on-off/remove_old_restic_cronjob.yml

13 lines
401 B
YAML
Raw Normal View History

---
- hosts: all
tasks:
- name: remove restic cronjob
become: yes
ansible.builtin.cron:
name: restic
state: absent
job: "/usr/local/bin/restic_backup.sh"
minute: "{{ 59|random(seed=inventory_hostname) }}"
hour: "{{ restic_cron_hours }}"
# siehe: https://stackoverflow.com/questions/33379378/idempotence-and-random-variables-in-ansible