Don't fail if cron isn't installed when setting up systemd timer (#147)

* `cron` isn't always installed and is not required when using a systemd
  timer, so make sure setup doesn't fail when we check if there's
  already an installed cron timer

Signed-off-by: Woomymy <woomy@woomy.be>
pull/135/merge
Woomy 2 months ago committed by GitHub
parent cbe280e7ff
commit 702299f861
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 2
      tasks/noauto_create_timer_systemd.yml

@ -6,11 +6,13 @@
state: absent
check_mode: true
register: cron_file_exists
ignore_errors: true
- name: Ensure no Borgmatic Cron file exists.
ansible.builtin.assert:
that:
- not cron_file_exists.changed
- not cron_file_exists.failed or "Failed to find" in cron_file_exists.msg
fail_msg: Found an existing Borgmatic Cron job. Please remove before using Systemd timer.
- name: Create borgbackup timer

Loading…
Cancel
Save