]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Ignore ssh configuration files when running ssh
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Thu, 31 Aug 2023 09:37:55 +0000 (11:37 +0200)
committerJörg Behrmann <behrmann@physik.fu-berlin.de>
Thu, 31 Aug 2023 16:20:11 +0000 (18:20 +0200)
When in a user namespace, the ssh config files from /etc/ will be
owned by nobody which makes ssh fail. Let's ignore these configuration
files when running ssh to avoid such failures.

Fixes #1848

mkosi/qemu.py

index 50d7a4868601b4e949f36a0711ac5c3b2c57d713..6c9fffe68428d978eecd534801120f9cd6354cc3 100644 (file)
@@ -336,6 +336,7 @@ def run_qemu(args: MkosiArgs, config: MkosiConfig) -> None:
 def run_ssh(args: MkosiArgs, config: MkosiConfig) -> None:
     cmd = [
         "ssh",
+        "-F", "none",
         # Silence known hosts file errors/warnings.
         "-o", "UserKnownHostsFile=/dev/null",
         "-o", "StrictHostKeyChecking=no",