diff --git a/swh/fuse/cli.py b/swh/fuse/cli.py --- a/swh/fuse/cli.py +++ b/swh/fuse/cli.py @@ -108,5 +108,7 @@ with ExitStack() as stack: if not foreground: - stack.enter_context(DaemonContext()) + # Stay in the current working directory when spawning daemon + cwd = os.getcwd() + stack.enter_context(DaemonContext(working_directory=cwd)) asyncio.run(fuse.main(swhids, path, ctx.obj["config"]))