From c667709d6f6dc08bd5ced9ffaa9b43cf10b6e570 Mon Sep 17 00:00:00 2001 From: Marc Herbert Date: Mon, 10 Mar 2025 21:20:40 +0000 Subject: [PATCH] Packages: add sshfs This allows the guest to mount any host directory "out of the box" with zero qemu or kernel feature to enable. Thanks to `dpipe` and "reverse sshfs", this does not require any additional ssh configuration either: https://blog.dhampir.no/content/reverse-sshfs-mounts-fs-push ``` dpipe /usr/lib/openssh/sftp-server = ssh CLIENT sshfs :/mnt/host/path /mnt/client/path -o slave ``` This Just Works out of the box. Just for the record, virtiofs and 9P are the most popular and likely much faster alternatives but sshfs is "good enough" in most cases. virtiofs seems to clash with what we already do ("NUMA distance missing" error, etc.) and 9P is rumoured to be quite slow too. Also add "ping" and friends on Arch Linux. Signed-off-by: Marc Herbert --- mkosi.arch.default.tmpl | 2 ++ mkosi.fedora.default.tmpl | 1 + mkosi.ubuntu.default.tmpl | 1 + 3 files changed, 4 insertions(+) diff --git a/mkosi.arch.default.tmpl b/mkosi.arch.default.tmpl index da07ef4..be7ab5e 100644 --- a/mkosi.arch.default.tmpl +++ b/mkosi.arch.default.tmpl @@ -17,6 +17,7 @@ Packages= iniparser inetutils iproute2 + iputils jq kmod libtraceevent @@ -29,6 +30,7 @@ Packages= numactl pciutils openssh + sshfs perl procps-ng python diff --git a/mkosi.fedora.default.tmpl b/mkosi.fedora.default.tmpl index 542100f..145c836 100644 --- a/mkosi.fedora.default.tmpl +++ b/mkosi.fedora.default.tmpl @@ -2,6 +2,7 @@ Packages= openssh-clients openssh-server + fuse-sshfs httpd ndctl daxctl diff --git a/mkosi.ubuntu.default.tmpl b/mkosi.ubuntu.default.tmpl index d50d382..68f058e 100644 --- a/mkosi.ubuntu.default.tmpl +++ b/mkosi.ubuntu.default.tmpl @@ -2,6 +2,7 @@ Packages= ndctl openssh-client + sshfs lsof strace ltrace