diff --git a/marauder/backup.nix b/marauder/backup.nix index b4637ab..58c2213 100755 --- a/marauder/backup.nix +++ b/marauder/backup.nix @@ -1,4 +1,4 @@ -{ pkgs, config, ... }: +{ pkgs, config, secrets, ... }: { environment.systemPackages = with pkgs; [ restic @@ -24,6 +24,14 @@ }; }; + environment.etc = { + "restic-env".text = '' + export B2_ACCOUNT_ID="${secrets.b2.accountId}" + export B2_ACCOUNT_KEY="${secrets.b2.accountKey}" + ''; + "restic-password".text = secrets.restic.password; + }; + services.restic.backups = { b2 = { initialize = true; diff --git a/secrets.json b/secrets.json index e4aa2b2..354060a 100644 Binary files a/secrets.json and b/secrets.json differ