diff --git a/modules/restic/system.nix b/modules/restic/system.nix index d9684b8..2b7844a 100644 --- a/modules/restic/system.nix +++ b/modules/restic/system.nix @@ -57,6 +57,10 @@ in type = lib.types.listOf lib.types.str; default = [ ]; }; + uploadLimit = lib.mkOption { + type = lib.types.nullOr lib.types.int; + default = 1500; + }; }; config = lib.mkIf cfg.enable { @@ -81,7 +85,7 @@ in "--exclude-file=${excludesFile}" "--tag system" "--verbose" - ]; + ] ++ lib.optional (cfg.uploadLimit != null) "--limit-upload=${toString cfg.uploadLimit}"; }; systemd.services."restic-backups-system".serviceConfig = {