bundles/zfs: use systemd-timers for zfs snapshots
All checks were successful
kunsi/bundlewrap/pipeline/head This commit looks good

This commit is contained in:
Franzi 2022-02-12 11:29:26 +01:00
parent c1bb43286d
commit 87bf6fac68
Signed by: kunsi
GPG key ID: 12E3D2136B818350

View file

@ -35,14 +35,6 @@ defaults = {
}, },
}, },
}, },
'cron': {
'jobs': {
'zfs-auto-snapshot-daily': '0 0 * * * root /usr/local/sbin/zfs-auto-snapshot daily',
'zfs-auto-snapshot-hourly': '0 * * * * root /usr/local/sbin/zfs-auto-snapshot hourly',
'zfs-auto-snapshot-monthly': '0 0 1 * * root /usr/local/sbin/zfs-auto-snapshot monthly',
'zfs-auto-snapshot-weekly': '0 0 * * 7 root /usr/local/sbin/zfs-auto-snapshot weekly',
},
},
'icinga2_api': { 'icinga2_api': {
'zfs': { 'zfs': {
'services': { 'services': {
@ -77,6 +69,26 @@ defaults = {
}, },
}, },
}, },
'systemd-timers': {
'timers': {
'zfs-auto-snapshot-daily': {
'when': 'daily',
'command': '/usr/local/sbin/zfs-auto-snapshot daily',
},
'zfs-auto-snapshot-hourly': {
'when': 'hourly',
'command': '/usr/local/sbin/zfs-auto-snapshot hourly',
},
'zfs-auto-snapshot-monthly': {
'when': 'monthly',
'command': '/usr/local/sbin/zfs-auto-snapshot monthly',
},
'zfs-auto-snapshot-weekly': {
'when': 'weekly',
'command': '/usr/local/sbin/zfs-auto-snapshot weekly',
},
},
},
'zfs': { 'zfs': {
'datasets': {}, 'datasets': {},
'pools': {}, 'pools': {},