nixos/qemu-vm: Ensure 9pnet_virtio module is loaded for shared dirs
When `diskImage = null`, the root fs is a tmpfs instead of `/dev/vda`. Thus, it doesn't have to wait for virtio modules to load before being mounted. The root fs is a dependency of shared directories by nature of being their parent directory. Without depending on `/dev/vda`, these shared directories may attempt to mount without virtio modules being loaded.
This commit is contained in:
@@ -1169,7 +1169,7 @@ in
|
|||||||
value.fsType = "9p";
|
value.fsType = "9p";
|
||||||
value.neededForBoot = true;
|
value.neededForBoot = true;
|
||||||
value.options =
|
value.options =
|
||||||
[ "trans=virtio" "version=9p2000.L" "msize=${toString cfg.msize}" ]
|
[ "trans=virtio" "version=9p2000.L" "msize=${toString cfg.msize}" "x-systemd.requires=modprobe@9pnet_virtio.service" ]
|
||||||
++ lib.optional (tag == "nix-store") "cache=loose";
|
++ lib.optional (tag == "nix-store") "cache=loose";
|
||||||
};
|
};
|
||||||
in lib.mkMerge [
|
in lib.mkMerge [
|
||||||
|
|||||||
Reference in New Issue
Block a user