diff options
author | Kjetil Orbekk <kj@orbekk.com> | 2021-03-11 08:24:55 -0500 |
---|---|---|
committer | Kjetil Orbekk <kj@orbekk.com> | 2021-03-11 08:24:55 -0500 |
commit | 8bf47ab9e1f042602faa07d65adaec6e45cb7f57 (patch) | |
tree | e83a50110e612c8515a224cdb8844931b5144e46 | |
parent | 00683d781c7604297c04770ee0c1669c2c255ffc (diff) |
update
-rw-r--r-- | config/borg-backup.nix | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/borg-backup.nix b/config/borg-backup.nix index 3a6fd7b..290cbc9 100644 --- a/config/borg-backup.nix +++ b/config/borg-backup.nix @@ -59,16 +59,16 @@ in path = with pkgs; [ borgbackup rsync openssh sshfs moreutils ]; startAt = "06:30"; serviceConfig = { - RuntimeDirectory = "backup-prober"; + PrivateTmp = true; }; environment = { BORG_KEY_FILE = "/opt/secret/borg-backup-keys/staging_backup"; BORG_RELOCATED_REPO_ACCESS_IS_OK = "yes"; }; script = '' - mkdir "$RUNTIME_DIRECTORY/mnt" - sshfs root@orbekk.osl.trygveandre.net:/storage "$RUNTIME_DIRECTORY/mnt" - REPOSITORY="$RUNTIME_DIRECTORY/backup" + mkdir -p "/tmp/mnt" + sshfs root@orbekk.osl.trygveandre.net:/storage "/tmp/mnt" + REPOSITORY="/tmp/mnt/backup" last_repo="$(borg list $REPOSITORY -P ${probe.repo} --last 1 --short)" target="${config.orbekk.monitoring-server.textFileDir}/backup_probe.prom" |