diff --git a/server/modules/backup.nix b/server/modules/backup.nix index 976816b..ed8abd3 100644 --- a/server/modules/backup.nix +++ b/server/modules/backup.nix @@ -3,6 +3,9 @@ age.secrets.restic-pw = { file = ../secrets/restic-pw.age; }; + age.secrets.restic-s3 = { + file = ../secrets/restic-s3.age; + }; services.restic = { backups = { localbackup = { @@ -16,6 +19,22 @@ ]; repository = "/mnt/2tb/restic"; }; + remotebackup = { + exclude = [ + "/home/*/.cache" + ]; + initialize = true; + passwordFile = config.age.secrets.restic-pw.path; + environmentFile = config.age.secrets.restic-s3.path; + paths = [ + "/home" + ]; + timerConfig = { + OnCalendar = "*-*-03,06,09,12,15,18,21,24,27,30 00:00:00"; + Persistent = true; + }; + repository = "s3:s3.us-west-002.backblazeb2.com/kop-bucket"; + }; }; }; -} \ No newline at end of file +} diff --git a/server/secrets/restic-s3.age b/server/secrets/restic-s3.age new file mode 100644 index 0000000..090fd10 --- /dev/null +++ b/server/secrets/restic-s3.age @@ -0,0 +1,10 @@ +age-encryption.org/v1 +-> ssh-ed25519 yfCCMw kIAiiVGrxQLT8tNcIehkSwAl0RIR8yCblKcJutHKfio +LlI57U6z2Rmzau3yGP7GwgE7axUSHazMZB87CUuvZIo +-> ssh-ed25519 IV3DkQ Lig+2cAx34B1GK28qm8dxfcdjezyjHgusJW4i1JiLFM +FPjcmohS8mLlNLhZsXXlYJB10nnUYZOJonnIQoxcfuY +-> T$pF-grease vM&|GOOo k"jB.( '3~O-3rS ++sxTmNCBIo/fFeSCisPlgGYrIJNZVh/ykKig7UonRDBNYCIq9GoC8MViYEtTOcfF +o13P+1O2apmVg84VclReTiEZOy96TgjUe8A6uc9+ +--- ah7cAYBdupOvrBoaJx1m8fTmSceC5Cq/2PPQOvZRTGA +ޣ ?4bh>m;"eGNLDI{e\W-ә`S;2VywNW_UFS2CXS