more refactoring

This commit is contained in:
Lennart J. Kurzweg (Nx2)
2026-01-13 15:06:37 +01:00
parent 6d8a7e7194
commit 4ed036b5d0
10 changed files with 20 additions and 18 deletions

View File

@@ -115,7 +115,7 @@
'';
nx_backup = let
destination = if hyper.host == "NxNORTH" then "${hyper.home}/shared/" else "${hyper.home}/backups/";
in pkgs.lib.mkIf (hyper.host == "NxXPS" || hyper.host == "NxNORTH") ''
in pkgs.lib.mkIf (hyper.isPersonal) ''
set RPATH (curl -s https://${hyper.domain}/latest-backup)
rsync -avz --info=progress2 -e "ssh -p ${builtins.toString secrets.ssh.port}" ${hyper.user}@ssh.${hyper.domain}:"$RPATH" ${destination}
'';