Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Configuration options

By including the microvm module a set of NixOS options is made available for customization. These are the most important ones:

OptionPurpose
microvm.hypervisorHypervisor to use by default in microvm.declaredRunner
microvm.vcpuNumber of Virtual CPU cores
microvm.memRAM allocation in MB
microvm.interfacesNetwork interfaces
microvm.volumesBlock device images
microvm.sharesShared filesystem directories
microvm.devicesPCI/USB devices for host-to-vm passthrough
microvm.socketControl socket for the Hypervisor so that a MicroVM can be shutdown cleanly
microvm.user(qemu only) User account which Qemu will switch to when started as root
microvm.forwardPorts(qemu user-networking only) TCP/UDP port forwarding
microvm.vfkit.extraArgs(vfkit only) Extra arguments to pass to vfkit
microvm.vfkit.logLevel(vfkit only) Log level: "debug", "info", or "error" (default: "info")
microvm.vfkit.rosetta.enable(vfkit only) Enable Rosetta for running x86_64 binaries on ARM64 (Apple Silicon only)
microvm.kernelParamsLike boot.kernelParams but will not end up in system.build.toplevel, saving you rebuilds
microvm.storeOnDiskEnables the store on the boot squashfs even in the presence of a share with the host's /nix/store
microvm.writableStoreOverlayOptional string of the path where all writes to /nix/store should go to.

See the options declarations for a full reference.