summaryrefslogtreecommitdiff
path: root/hosts/vidhar/borg
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2022-02-17 19:28:36 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2022-02-17 19:28:36 +0100
commit4cf690efccb04e8fe19f232325cffa7fe55d4dd0 (patch)
tree425990c213e7ab7f1eae5613defb62bdae4355b6 /hosts/vidhar/borg
parentdde33b0ebd3ddd1645c8e80529afef129a8dca86 (diff)
downloadnixos-4cf690efccb04e8fe19f232325cffa7fe55d4dd0.tar
nixos-4cf690efccb04e8fe19f232325cffa7fe55d4dd0.tar.gz
nixos-4cf690efccb04e8fe19f232325cffa7fe55d4dd0.tar.bz2
nixos-4cf690efccb04e8fe19f232325cffa7fe55d4dd0.tar.xz
nixos-4cf690efccb04e8fe19f232325cffa7fe55d4dd0.zip
vidhar: ...
Diffstat (limited to 'hosts/vidhar/borg')
-rwxr-xr-xhosts/vidhar/borg/copy.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/hosts/vidhar/borg/copy.py b/hosts/vidhar/borg/copy.py
index a1c40c98..979dc5f4 100755
--- a/hosts/vidhar/borg/copy.py
+++ b/hosts/vidhar/borg/copy.py
@@ -103,9 +103,9 @@ def copy_archive(src_repo_path, dst_repo_path, entry):
103 subprocess.run(['mount', '-t', 'overlay', 'overlay', '-o', f'lowerdir=/,upperdir={upper},workdir={work}', chroot], check=True) 103 subprocess.run(['mount', '-t', 'overlay', 'overlay', '-o', f'lowerdir=/,upperdir={upper},workdir={work}', chroot], check=True)
104 bindMounts = ['nix', 'run', 'proc', 'dev', 'sys', pathlib.Path(os.path.expanduser('~')).relative_to('/')] 104 bindMounts = ['nix', 'run', 'proc', 'dev', 'sys', pathlib.Path(os.path.expanduser('~')).relative_to('/')]
105 if os.environ.get('BORG_BASE_DIR'): 105 if os.environ.get('BORG_BASE_DIR'):
106 bindMounts.append(os.environ['BORG_BASE_DIR'].relative_to('/')) 106 bindMounts.append(pathlib.Path(os.environ['BORG_BASE_DIR']).relative_to('/'))
107 if os.environ.get('CREDENTIALS_DIRECTORY'): 107 if os.environ.get('CREDENTIALS_DIRECTORY'):
108 bindMounts.append(os.environ['CREDENTIALS_DIRECTORY'].relative_to('/')) 108 bindMounts.append(pathlib.Path(os.environ['CREDENTIALS_DIRECTORY']).relative_to('/'))
109 if not ":" in src_repo_path: 109 if not ":" in src_repo_path:
110 bindMounts.append(pathlib.Path(src_repo_path).relative_to('/')) 110 bindMounts.append(pathlib.Path(src_repo_path).relative_to('/'))
111 if 'SSH_AUTH_SOCK' in os.environ: 111 if 'SSH_AUTH_SOCK' in os.environ: