From 90c9d4da929bf09c4666b00ee9334a213b8bcf29 Mon Sep 17 00:00:00 2001 From: teutat3s Date: Thu, 7 Nov 2024 18:06:33 +0100 Subject: [PATCH] invoiceplane: fix backupPrepareCommand command --- hosts/fae/invoiceplane.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/fae/invoiceplane.nix b/hosts/fae/invoiceplane.nix index 9d2b0c64..7bb85b28 100644 --- a/hosts/fae/invoiceplane.nix +++ b/hosts/fae/invoiceplane.nix @@ -72,7 +72,7 @@ in # See https://www.hosting.de/blog/verschluesselte-backups-mit-rclone-und-restic-in-nextcloud/ repository = "rclone:cloud.pub.solar:/Backups/InvoicePlane"; backupPrepareCommand = '' - ${pkgs.mariadb-client}/bin/mariadb-dump --all-databases --user=invoiceplane > "${backupDir}/invoiceplane-mariadb-dump.sql" + ${pkgs.sudo}/bin/sudo -u invoiceplane ${pkgs.mariadb-client}/bin/mariadb-dump --all-databases --user=invoiceplane > "${backupDir}/invoiceplane-mariadb-dump.sql" ''; rcloneConfigFile = config.age.secrets."fae-rclone.conf.age".path; };