From adf1ccd78faaea3c32a387952830b73c98af49a0 Mon Sep 17 00:00:00 2001 From: Lucas De Marchi Date: Tue, 19 Feb 2019 13:54:56 -0800 Subject: [PATCH] arch: kill dirmngr only Using fuser to identify processes using a path doesn't work as I wanted: it relies on the filesystem mounted there. The outcome is that when using "-t directory" it will try to kill all processes using that filesystem rather than processes using files under that path. Even by bind-mounting root so it's always a mountpoint, it doesn't work. So instead of killing everything, pinpoint what process pacman/pacstrap left running and kill only that one. Right now this means telling dirmngr to exit. --- mkosi | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/mkosi b/mkosi index 6fdd96531..c44f61ad3 100755 --- a/mkosi +++ b/mkosi @@ -1828,6 +1828,7 @@ SigLevel = Required DatabaseOptional TrustAll # Kill the gpg-agent used by pacman and pacman-key run(['gpg-connect-agent', '--homedir', os.path.join(root, 'etc/pacman.d/gnupg'), 'KILLAGENT', '/bye']) + run(['gpg-connect-agent', '--homedir', os.path.join(root, 'etc/pacman.d/gnupg'), '--dirmngr', 'KILLDIRMNGR', '/bye']) if "networkmanager" in args.packages: enable_networkmanager(workspace) @@ -1842,9 +1843,6 @@ SigLevel = Required DatabaseOptional TrustAll with open(os.path.join(workspace, 'root', 'etc/locale.conf'), 'w') as f: f.write('LANG=en_US.UTF-8\n') - # At this point, no process should be left running, kill then - run(["fuser", "-c", root, "--kill"]) - @completestep('Installing openSUSE') def install_opensuse(args: CommandLineArguments, workspace: str, run_build_script: bool) -> None: -- 2.47.2