From 1d41e387650244f361335ee73ae2658d240d6154 Mon Sep 17 00:00:00 2001
From: Lukas Wurzinger <lukas@wrz.one>
Date: Sun, 5 Jan 2025 01:06:14 +0100
Subject: [PATCH] fix

---
 hosts/server/vessel/backup.nix   | 7 ++++---
 hosts/server/vessel/musicomp.nix | 3 ++-
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/hosts/server/vessel/backup.nix b/hosts/server/vessel/backup.nix
index 66e4156..02ae2b9 100644
--- a/hosts/server/vessel/backup.nix
+++ b/hosts/server/vessel/backup.nix
@@ -20,9 +20,9 @@ in {
         description = "Local rsync Backup ${backupName}";
         wantedBy = ["timers.target"];
         timerConfig = {
-          OnCalendar = "*-*-* 03:00:00";
+          OnCalendar = "*-*-* 03:00:00"; # TODO
           Persistent = true;
-          Unit = "${systemdName}.service";
+          Unit = "${systemdName}.service"; # TODO
         };
       };
 
@@ -33,6 +33,7 @@ in {
           User = "root";
           Group = "root";
         };
+        # TODO
         script = ''
           ${lib.getExe pkgs.rsync} --verbose --verbose --archive --update --delete --mkpath -- ${backups.${backupName}}/ /srv/backup/${backupName}/
         '';
@@ -52,7 +53,7 @@ in {
     passwordFile = config.age.secrets."restic-${attrName}".path;
     pruneOpts = ["--keep-daily 7" "--keep-weekly 5" "--keep-monthly 12"];
     timerConfig = {
-      OnCalendar = "*-*-* 03:00:00";
+      OnCalendar = "*-*-* 03:00:00"; # TODO
       Persistent = true;
     };
     extraOptions = ["sftp.args='-i /etc/ssh/ssh_host_ed25519_key -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null'"];
diff --git a/hosts/server/vessel/musicomp.nix b/hosts/server/vessel/musicomp.nix
index 6c1fdae..ed4c090 100644
--- a/hosts/server/vessel/musicomp.nix
+++ b/hosts/server/vessel/musicomp.nix
@@ -15,6 +15,7 @@
     post = let
       remoteDir = self.nixosConfigurations.abacus.config.services.navidrome.settings.MusicFolder;
       rsyncExe = lib.getExe pkgs.rsync;
+      rsh = "${lib.getExe pkgs.openssh} -i /etc/ssh/ssh_host_ed25519_key -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null";
     in ''
       ${rsyncExe} \
         --archive \
@@ -24,7 +25,7 @@
         --mkpath \
         --verbose --verbose \
         --exclude lost+found \
-        --rsh 'ssh -i /etc/ssh/ssh_host_ed25519_key -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null' \
+        --rsh ${lib.escapeShellArg rsh} \
         /srv/compmusic/ root@wrz.one:${remoteDir}
     '';
   };