stop masto server before backups to try to prevent ooms

This commit is contained in:
Cyryl Płotnicki 2023-05-25 12:11:24 +01:00
parent cfc40ca8c7
commit f28b7476c8

View file

@ -25,8 +25,12 @@ in rec {
repository = "b2:cyplo-restic-vpsfree";
backupPrepareCommand = ''
mkdir -p ${containersBackupPath}/
systemctl stop container@mastodon.service
${pkgs.podman}/bin/podman volume export woodpecker-server-data -o ${containersBackupPath}/woodpecker.tar
'';
backupCleanupCommand = ''
systemctl start container@mastodon.service
'';
timerConfig = { OnCalendar = "hourly"; };
environmentFile =
"${config.sops.secrets.restic-backups-b2-environment.path}";