modules/backup: add restic cache
This commit is contained in:
parent
9dae541043
commit
3d13a0136f
@ -41,6 +41,7 @@ let
|
|||||||
export RESTIC_PASSWORD_FILE=${jobPasswordFile}
|
export RESTIC_PASSWORD_FILE=${jobPasswordFile}
|
||||||
export RESTIC_REPOSITORY="rest:https://${targetUsername}:$(cat ${targetPasswordFile})@${targetOptions.serverName}${repoPath}"
|
export RESTIC_REPOSITORY="rest:https://${targetUsername}:$(cat ${targetPasswordFile})@${targetOptions.serverName}${repoPath}"
|
||||||
export RESTIC_PROGRESS_FPS=0.1
|
export RESTIC_PROGRESS_FPS=0.1
|
||||||
|
export RESTIC_CACHE_DIR=/var/cache/restic
|
||||||
|
|
||||||
restic snapshots || restic init
|
restic snapshots || restic init
|
||||||
|
|
||||||
@ -125,5 +126,8 @@ in
|
|||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
systemd.services = backupServiceUnits;
|
systemd.services = backupServiceUnits;
|
||||||
systemd.timers = backupServiceTimers;
|
systemd.timers = backupServiceTimers;
|
||||||
|
systemd.tmpfiles.rules = [
|
||||||
|
"d /var/cache/restic - - - - -"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user