summary refs log tree commit diff
path: root/nixos/modules/services/backup/borgbackup.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/modules/services/backup/borgbackup.nix')
-rw-r--r--nixos/modules/services/backup/borgbackup.nix2
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos/modules/services/backup/borgbackup.nix b/nixos/modules/services/backup/borgbackup.nix
index cb2c4d6381f..05f222d5fbe 100644
--- a/nixos/modules/services/backup/borgbackup.nix
+++ b/nixos/modules/services/backup/borgbackup.nix
@@ -108,6 +108,8 @@ let
       timerConfig = {
         Persistent = cfg.persistentTimer;
       };
+      # if remote-backup wait for network
+      after = optional (cfg.persistentTimer && !isLocalPath cfg.repo) "network-online.target";
     };
 
   # utility function around makeWrapper