Configure backup for Nextcloud

This commit is contained in:
Paul-Henri Froidmont 2021-07-17 01:02:26 +02:00
parent 39f20ed89d
commit fa9752c4ba
Signed by: phfroidmont
GPG key ID: BE948AFD7E7873BE
3 changed files with 13 additions and 4 deletions

View file

@ -5,6 +5,11 @@ let
in
{
options.services.custom-backup-job = {
additionalPaths = mkOption {
type = with types; listOf path;
default = [ ];
};
additionalReadWritePaths = mkOption {
type = with types; listOf path;
default = [ ];
@ -23,7 +28,7 @@ in
config = {
services.borgbackup.jobs.data = {
paths = [ "/nix/var/data" ];
paths = [ "/nix/var/data" ] ++ cfg.additionalPaths;
doInit = false;
repo = "backup@212.129.12.205:./";
encryption = {