mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-04-24 12:19:12 +00:00
hosts/plover: modularize Borg backup paths
This commit is contained in:
parent
752053b755
commit
f27b7e045c
@ -196,20 +196,8 @@ in
|
|||||||
services-backup = jobCommonSettings
|
services-backup = jobCommonSettings
|
||||||
{
|
{
|
||||||
paths = [
|
paths = [
|
||||||
# Vaultwarden.
|
# ACME accounts and TLS certificates
|
||||||
"/var/lib/bitwarden_rs"
|
"/var/lib/acme"
|
||||||
|
|
||||||
# Gitea.
|
|
||||||
config.services.gitea.dump.backupDir
|
|
||||||
|
|
||||||
# PostgreSQL database dumps.
|
|
||||||
config.services.postgresqlBackup.location
|
|
||||||
|
|
||||||
# ACME accounts.
|
|
||||||
"/var/lib/acme/.lego/accounts"
|
|
||||||
|
|
||||||
# Zone files.
|
|
||||||
"/etc/bind/zones"
|
|
||||||
];
|
];
|
||||||
repo = borgRepo "services";
|
repo = borgRepo "services";
|
||||||
passCommand = "cat ${config.sops.secrets."plover/borg/repos/services/password".path}";
|
passCommand = "cat ${config.sops.secrets."plover/borg/repos/services/password".path}";
|
||||||
|
@ -300,4 +300,7 @@ in
|
|||||||
filter = named-refused[journalmatch='_SYSTEMD_UNIT=bind.service']
|
filter = named-refused[journalmatch='_SYSTEMD_UNIT=bind.service']
|
||||||
maxretry = 3
|
maxretry = 3
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
# Add the following to be backed up.
|
||||||
|
services.borgbackup.jobs.services-backup.paths = [ zonesDir ];
|
||||||
}
|
}
|
||||||
|
@ -207,4 +207,7 @@ in
|
|||||||
"L+ ${giteaCustomDir}/public/img/logo.svg - - - - ${../../files/gitea/logo.svg}"
|
"L+ ${giteaCustomDir}/public/img/logo.svg - - - - ${../../files/gitea/logo.svg}"
|
||||||
"L+ ${giteaCustomDir}/public/img/logo.png - - - - ${../../files/gitea/logo.png}"
|
"L+ ${giteaCustomDir}/public/img/logo.png - - - - ${../../files/gitea/logo.png}"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Add the following files to be backed up.
|
||||||
|
services.borgbackup.jobs.services-backup.paths = [ config.services.gitea.dump.backupDir ];
|
||||||
}
|
}
|
||||||
|
@ -75,4 +75,7 @@ in
|
|||||||
security.acme.certs."${postgresqlDomain}".postRun = ''
|
security.acme.certs."${postgresqlDomain}".postRun = ''
|
||||||
systemctl restart postgresql.service
|
systemctl restart postgresql.service
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
# Add the dumps to be backed up.
|
||||||
|
services.borgbackup.jobs.services-backup.paths = [ config.services.postgresqlBackup.location ];
|
||||||
}
|
}
|
||||||
|
@ -195,4 +195,7 @@ in
|
|||||||
ignoreregex =
|
ignoreregex =
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Add the data directory to be backed up.
|
||||||
|
services.borgbackup.jobs.services-backup.paths = [ "/var/lib/bitwarden_rs" ];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user