fmt: better formatting of the backup server file
This commit is contained in:
parent
3d6a1ba696
commit
e94683c3d5
1 changed files with 12 additions and 8 deletions
|
@ -144,14 +144,15 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
config =
|
||||
config = mkMerge [
|
||||
{
|
||||
# these values are anabled for every client
|
||||
environment.systemPackages = with pkgs; [
|
||||
restic
|
||||
];
|
||||
}
|
||||
// mkIf cfg.server.enable {
|
||||
|
||||
(mkIf cfg.server.enable {
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
cfg.server.port
|
||||
];
|
||||
|
@ -171,8 +172,9 @@ in {
|
|||
appendOnly = cfg.server.appendOnly;
|
||||
privateRepos = true;
|
||||
};
|
||||
}
|
||||
// mkIf enable_client {
|
||||
})
|
||||
|
||||
(mkIf enable_client {
|
||||
# client stuff here
|
||||
|
||||
# A list of all login accounts. To create the password hashes, use
|
||||
|
@ -181,15 +183,17 @@ in {
|
|||
|
||||
age.secrets.restic.file = ../secrets/backup/restic.age;
|
||||
|
||||
services.restic.backups =
|
||||
services.restic.backups = mkMerge [
|
||||
ownServers
|
||||
// {
|
||||
{
|
||||
# merge teh two configs together
|
||||
# backblaze = base // {
|
||||
# # backupos for each server are stored in a folder under their name
|
||||
# repository = "b2:NixOS-Main2:/${config.services.skynet.host.name}";
|
||||
# #environmentFile = config.age.secrets.backblaze.path;
|
||||
# };
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue