mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 23:11:34 +01:00
Run all restic backups as root
This commit is contained in:
parent
f5e59e0d12
commit
2e53bdb015
7 changed files with 11 additions and 43 deletions
|
|
@ -3,14 +3,12 @@ let
|
|||
cfg = config.custom.services.nextcloud;
|
||||
|
||||
dataDir = config.services.nextcloud.home;
|
||||
user = config.users.users.nextcloud.name;
|
||||
in
|
||||
{
|
||||
options.custom.services.nextcloud.backups.enable = lib.mkEnableOption "";
|
||||
|
||||
config = lib.mkIf cfg.backups.enable {
|
||||
custom.services.resticBackups.nextcloud = {
|
||||
inherit user;
|
||||
extraConfig = {
|
||||
backupPrepareCommand = ''
|
||||
${lib.getExe' config.services.nextcloud.occ "nextcloud-occ"} maintenance:mode --on
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue