1
0
Fork 0

server10: add znapzend backups of microvms to server8

This commit is contained in:
Astro 2023-01-01 02:51:03 +01:00
parent 046e6d4828
commit cfd36714ac
2 changed files with 28 additions and 0 deletions

View File

@ -4,6 +4,7 @@
imports = [
./hardware-configuration.nix
./microvm-staging.nix
./znapzend.nix
];
c3d2 = {

View File

@ -0,0 +1,27 @@
# Quick full backups of all service MicroVM datasets.
# server10 runs services, server8+9 have the storage.
{
services.znapzend = {
enable = true;
logLevel = "info";
autoCreation = true;
# override preexisting zetups
pure = true;
zetup = {
"server10/vm" = {
recursive = true;
# keep a day of hourly snapshots locally on server10
plan = "24h => 1h";
destinations = {
server8 = rec {
dataset = "server8_hdd/backups/server10/vm";
host = "server8.cluster.zentralwerk.org";
plan = "2h => 1h, 7d => 24h";
# just always work
presend = "ssh-keygen -F ${host} >/dev/null || ssh-keyscan ${host} >> .ssh/known_hosts";
};
};
};
};
};
}