VM Configuration Format

Technical Rev 1.0

Each VM stores its configuration as config.json in its folder under the data directory. This document describes the schema. The same model underlies the GUI settings dialogs and the CLI. For the user view, see Creating Virtual Machines.

Top-Level VmConfig #

FieldTypeDescription
idstringUnique VM identifier (UUID).
namestringDisplay name.
os_typeOsTypeGuest operating system.
cpuCpuConfigCPU topology and options.
memoryMemoryConfigRAM size and ballooning.
disksDiskAttachment[]Attached virtual disks.
networkNetworkAttachment[]Network adapters.
displayDisplayConfigDisplay backend and graphics.
boot_orderBootDevice[]Boot device priority.
usbUsbConfigUSB controller and passthrough.
shared_foldersSharedFolderConfig[]Host-guest shared folders.
encryptionEncryptionConfig?Optional disk encryption settings.
unattendedUnattendedConfig?Optional unattended-install settings.
cdromstring?Path to an ISO mounted as CD-ROM.
ssh_host_portu16?Host port forwarded to guest SSH (port 22) in NAT mode.
descriptionstringFree-text description.
tagsstring[]Organizational tags.

Enums #

OsType

Windows11, Windows10, WindowsServer2022, Ubuntu2404, Ubuntu2204, Fedora40, Debian12, Arch, FreeBSD14, MacOS, KaliLinux, Rocky9, AlmaLinux9, Other(string).

DiskFormat

Qcow2, Raw, Vmdk, Vdi, Qvd (encrypted QCOW2).

DiskBus

VirtIO, Sata, Ide, NVMe.

NetworkMode

Nat, Bridged, HostOnly, Internal.

NetworkAdapter

VirtIO, E1000 (Intel PRO/1000), Rtl8139.

DisplayBackend

Spice, Vnc, Sdl.

BootDevice

Disk, Cdrom, Network, Usb.

UsbVersion

Usb2 (EHCI), Usb3 (xHCI).

Nested Structures #

CpuConfig

FieldTypeDefaultDescription
coresu322vCPU cores.
threads_per_coreu321Threads per core (SMT).
nested_virtboolfalseEnable nested virtualization.

MemoryConfig

FieldTypeDefaultDescription
size_mbu644096RAM in megabytes.
balloonbooltrueEnable memory ballooning.

DiskAttachment

FieldTypeDescription
pathstringPath to the disk image.
formatDiskFormatImage format.
size_bytesu64Virtual size.
encryptedboolLUKS encryption (QCOW2/QVD).
read_onlyboolMount read-only.
busDiskBusController bus.

NetworkAttachment

FieldTypeDescription
modeNetworkModeConnectivity mode.
mac_addressstring?MAC (auto-generated if absent).
adapterNetworkAdapterNIC model.

DisplayConfig

FieldTypeDefaultDescription
backendDisplayBackendSpiceDisplay protocol.
gpu_accelboolfalseGPU acceleration.
resolution(u32, u32)(1920, 1080)Display resolution.
fullscreenboolfalseFullscreen flag.

UsbConfig

FieldTypeDefaultDescription
enabledbooltrueEnable USB controllers.
versionUsbVersionUsb3USB controller version.
passthroughUsbPassthrough[]emptyPassed-through devices.

UsbPassthrough: vendor_id (u16), product_id (u16), label (string).

SharedFolderConfig

FieldTypeDescription
namestringMount name / tag.
host_pathstringHost directory.
read_onlyboolRead-only access.
auto_mountboolAuto-mount at boot.

EncryptionConfig

FieldTypeDescription
enabledboolEncryption on/off.
key_idstringWrapping-key identifier.
algorithmstringAlgorithm name (e.g. ML-KEM-768+AES-256-GCM).

UnattendedConfig

FieldTypeDescription
enabledboolEnable unattended install.
usernamestringFirst user account.
passwordstringUser password.
hostnamestringGuest hostname.
localestringLocale (e.g. en-US).
timezonestringIANA timezone (e.g. America/New_York).

Defaults at a Glance #

A newly created VM defaults to: 2 cores x 1 thread, 4096 MB RAM (balloon on), a SPICE display at 1920x1080 with no GPU acceleration, USB enabled at USB 3.0 (xHCI), a boot order of [Disk, Cdrom], and a single NAT adapter using the VirtIO NIC.

Note: Field names and enum variants above are taken from the implementation. Treat the JSON as managed by QuantaBox -- edit through the GUI or CLI rather than by hand to avoid producing an invalid configuration.