From 1fc4e9d0d97a1142b03540beed04b235b459c3d3 Mon Sep 17 00:00:00 2001 From: Michael Grote Date: Thu, 3 Aug 2023 15:33:29 +0200 Subject: [PATCH] fix: sanoid: missing systemd-units (#563) Reviewed-on: https://git.mgrote.net/mg/homeserver/pulls/563 Co-authored-by: Michael Grote Co-committed-by: Michael Grote --- group_vars/all.yml | 2 +- host_vars/pbs.grote.lan.yml | 2 +- roles/mgrote.zfs_sanoid/tasks/main.yml | 13 +++++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/group_vars/all.yml b/group_vars/all.yml index 38c140bf..f78e72ee 100644 --- a/group_vars/all.yml +++ b/group_vars/all.yml @@ -239,7 +239,7 @@ autoprune: 'yes' ### mgrote.zfs_sanoid - sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.0.deb + sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.4.deb # Ansible Variablen ### User diff --git a/host_vars/pbs.grote.lan.yml b/host_vars/pbs.grote.lan.yml index daa4b616..3605beb8 100644 --- a/host_vars/pbs.grote.lan.yml +++ b/host_vars/pbs.grote.lan.yml @@ -165,7 +165,7 @@ - http://192.168.2.43:3344/bash-helper-scripts-mgrote-latest.deb # weil pbs den fqdn nicht auflösen kann ### mgrote.zfs_sanoid - sanoid_deb_url: http://192.168.2.43:3344/sanoid_3.0.0.deb # weil pbs den fqdn nicht auflösen kann + sanoid_deb_url: http://192.168.2.43:3344/sanoid_3.0.4.deb # weil pbs den fqdn nicht auflösen kann ### mgrote.munin-node munin_node_allowed_cidrs: [192.168.3.0/24] diff --git a/roles/mgrote.zfs_sanoid/tasks/main.yml b/roles/mgrote.zfs_sanoid/tasks/main.yml index a648adf8..9390048e 100644 --- a/roles/mgrote.zfs_sanoid/tasks/main.yml +++ b/roles/mgrote.zfs_sanoid/tasks/main.yml @@ -38,6 +38,19 @@ - sanoid_snaps_enable is defined - sanoid_snaps_enable + - name: ensure service are started + become: true + ansible.builtin.systemd: + state: started + name: "{{ item }}" + daemon_reload: true + masked: false + enabled: yes + loop: + - sanoid.service + - sanoid-prune.service + - sanoid.timer + - name: include source-host tasks include_tasks: source.yml when: