obs-portal: fix backups, docker command does not need a TTY #233

Merged
teutat3s merged 2 commits from obs-backup-fix into main 2024-09-09 15:43:14 +00:00

View file

@ -154,11 +154,11 @@ in
"/tmp/obs-portal-backup.sql" "/tmp/obs-portal-backup.sql"
]; ];
timerConfig = { timerConfig = {
OnCalendar = "*-*-* 00:30:00 Etc/UTC"; OnCalendar = "*-*-* 01:30:00 Etc/UTC";
}; };
initialize = true; initialize = true;
backupPrepareCommand = '' backupPrepareCommand = ''
${pkgs.docker}/bin/docker exec -ti --user postgres obs-portal-db pg_dump obs > /tmp/obs-portal-backup.sql ${pkgs.docker}/bin/docker exec -i --user postgres obs-portal-db pg_dump obs > /tmp/obs-portal-backup.sql
''; '';
backupCleanupCommand = '' backupCleanupCommand = ''
rm /tmp/obs-portal-backup.sql rm /tmp/obs-portal-backup.sql