]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Make sure we have the same working directory in run_with_apivfs()
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Sat, 15 Apr 2023 06:29:04 +0000 (08:29 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Sat, 15 Apr 2023 06:31:01 +0000 (08:31 +0200)
By default, bubblewrap uses / as the working directory, let's make
sure that we remain in the same directory in run_with_apivfs().

mkosi/run.py

index ade636ffeadabd3e7e9dca7c161decb40d5a417b..88107d6b54e932cf4679d10f8d6a9fbb724db2d3 100644 (file)
@@ -259,6 +259,7 @@ def run_with_apivfs(
         # Required to make chroot detection via /proc/1/root work properly.
         "--unshare-pid",
         "--dev-bind", "/", "/",
+        "--chdir", Path.cwd(),
         "--tmpfs", state.root / "run",
         "--tmpfs", state.root / "tmp",
         "--proc", state.root / "proc",