nixfiles/hosts/hetzner-arm/containers/storage/profiles/rcloneSync.nix

54 lines
1.5 KiB
Nix
Raw Permalink Normal View History

2024-03-09 22:18:26 +00:00
{self, ...}: let
backupSchedules = import "${self}/data/backupSchedules.nix";
in {
2023-09-18 03:56:58 +01:00
services.rclone-sync = {
2022-11-15 14:52:49 +00:00
enable = true;
user = "storage";
2023-09-18 03:56:58 +01:00
syncJobs = map (syncJob:
syncJob
// {
2024-03-09 22:18:26 +00:00
timerConfig = backupSchedules.remoteBackups;
2023-09-18 03:56:58 +01:00
extraArgs = [
"--fast-list"
"--check-first"
"--delete-before"
"--b2-upload-concurrency=4"
"--transfers=4"
"--bwlimit 80M"
2023-09-18 03:56:58 +01:00
];
}) [
2022-11-15 14:52:49 +00:00
# Pheonix System's B2
{
source = "Storage:Backups";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Backups";
2023-03-19 11:44:27 +00:00
id = "phoenix_b2_backups";
2022-11-15 14:52:49 +00:00
}
{
source = "Storage:Photos";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Photos";
2023-03-19 11:44:27 +00:00
id = "phoenix_b2_photos";
2022-11-15 14:52:49 +00:00
}
{
source = "Storage:Music";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Music";
2023-03-19 11:44:27 +00:00
id = "phoenix_b2_music";
2022-11-15 14:52:49 +00:00
}
2023-07-09 20:46:08 +01:00
{
source = "Storage:Personal";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Personal";
2023-07-09 20:46:08 +01:00
id = "phoenix_b2_personal";
}
2023-07-29 20:35:27 +01:00
{
source = "Storage:Public";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Public";
2023-07-29 20:35:27 +01:00
id = "phoenix_b2_public";
}
2024-04-28 11:54:10 +01:00
{
source = "B2-Chaos-Notes:Chaos-Notes";
dest = "B2-Phoenix-Cryptidz-Storage:Phoenix-Cryptidz-Storage/Notes";
2024-04-28 11:54:10 +01:00
id = "phoenix_b2_notes";
}
2022-11-15 14:52:49 +00:00
];
};
}