]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Make entire /run available to gpg command
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 17 Sep 2024 18:54:37 +0000 (20:54 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 17 Sep 2024 18:57:47 +0000 (20:57 +0200)
gpg connects to various sockets in /run so let's make the entirety
of /run available to it.

mkosi/__init__.py

index 91ef1eb9280194eeb3819eddb47cb4ea2ccf1f2c..688c8de438c7c77aff252c819329572ba27fb678 100644 (file)
@@ -2032,12 +2032,9 @@ def calculate_signature(context: Context) -> None:
     options: list[PathString] = [
         "--bind", home, home,
         "--bind", context.staging, workdir(context.staging),
+        "--bind", "/run", "/run",
     ]
 
-    # gpg can communicate with smartcard readers via this socket so bind mount it in if it exists.
-    if (p := Path("/run/pcscd/pcscd.comm")).exists():
-        options += ["--bind", p, p]
-
     with (complete_step("Signing SHA256SUMS…")):
         run(
             cmdline,