Environment Variables

August 18, 2026 ยท View on GitHub

This page lists all the environment variables that can be used to configure the container.

An empty default means the variable is unset and its value is determined automatically when applicable.

๐ŸŽ macOS

VariableDefaultDescription
VERSION14macOS version to install, such as 14 or sonoma.
MODELiMacPro1,1Mac model identifier used by OpenCore.
SNMac serial number. Generated automatically when unset.
MLBMac board serial number. Generated automatically when unset.
UUIDMac system UUID. Generated automatically when unset.
CONNECTIONS4Number of connections used for recovery image download.

๐Ÿง  CPU and Memory

VariableDefaultDescription
CPU_CORES1Number of virtual CPU cores, such as 4, half, or max.
CPU_MODELQEMU CPU model. Selected automatically for Intel or AMD hosts when unset.
CPU_FLAGSAdditional QEMU CPU flags.
SMPCustom CPU topology. Determined from CPU_CORES when unset.
KVMYEnables KVM hardware acceleration.
RAM_SIZE4GAmount of RAM assigned to macOS, such as 8G, half, or max.
RAM_CHECKYChecks whether enough host memory is available before starting macOS.

๐Ÿ’พ Storage

VariableDefaultDescription
DISK_SIZE64GSize of the primary disk.
DISK_FMTrawDisk image format: raw or qcow2.
DISK_TYPEblkDisk device type, such as ide, scsi, or blk.
DISK_CACHEnoneDisk cache mode, such as none or writeback.
DISK_IOnativeDisk I/O mode, such as native, threads, or io_uring.
DISK_DISCARDunmapDiscard/TRIM mode for the primary disk.
DISK_ROTATION1Rotation rate reported to the guest. Use 1 to identify the disk as an SSD.
DISK_FLAGSAdditional options used when creating qcow2 disks.
DISK_OPTIONSAdditional options appended to QEMU disk devices.
ALLOCATENPreallocates space for the primary disk.
STORAGE/storageStorage directory used for disks, firmware variables, and downloads.

๐ŸŒ Networking

VariableDefaultDescription
NETWORKNetwork mode, such as nat, user, or N to disable networking.
DHCPNEnables macvtap networking so macOS receives a DHCP address.
HOSTOptional macOS computer name and advertised network hostname.
IPOverrides the automatically selected guest IPv4 address.
MACGuest network adapter MAC address. Generated automatically when unset.
ADAPTERvirtio-net-pciQEMU network adapter model.
DEVeth0Container network interface used as the uplink.
MTUMTU assigned to the guest network interface.
MASK255.255.255.0IPv4 netmask for guest network.
TAPqemuTAP or macvtap interface name.
BRIDGEdockerBridge name used for NAT networking.
HOST_PORTSPorts excluded from guest forwarding.
USER_PORTSAdditional ports to forward to macOS when using user-mode networking.
DNSMASQ_OPTSAdditional options passed to dnsmasq.
DNSMASQ_DEBUGNEnables dnsmasq debug output.
DNSMASQ_DISABLENDisables the internal dnsmasq resolver.
PASST_OPTSAdditional options passed to passt.
PASST_DEBUGNEnables passt debug output.

๐Ÿ–ฅ๏ธ Display

VariableDefaultDescription
DISPLAYwebDisplay backend, such as web, vnc, disabled, or none.
VGAvmwareQEMU video adapter model.
WIDTH1920Display width configured for macOS and OpenCore.
HEIGHT1080Display height configured for macOS and OpenCore.
GPUNEnables experimental GPU acceleration.
RENDERNODE/dev/dri/renderD128Render node used for GPU acceleration.

๐ŸŒ Web UI

VariableDefaultDescription
WEBYEnables the web interface.
WEB_PORT8006Port for the web interface.
VNC_PORT5900Port for the VNC server.
LOSSYNEnables lossy VNC compression to reduce bandwidth usage.
AUDIONStreams guest audio to the web viewer.
PROTECTNEnables password protection for the web interface.

โš™๏ธ System

VariableDefaultDescription
MACHINEq35QEMU machine type.
PCI_BUSpcie.0Overrides the PCI bus used for attached devices.
RNGYAdds the Virtio RNG device to the machine.
HPEToffHPET timer setting.
VMPORToffVMware port setting.
MOUSEusb-tabletPointing device used by the machine.
SOUNDusb-audioAudio device used when AUDIO=Y.
ARGUMENTSAdditional raw arguments appended to the QEMU command line.

๐Ÿš€ Boot

VariableDefaultDescription
PICKERNShows the OpenCore boot picker.
SMMNEnables System Management Mode.
LOGOYEnables the custom boot logo.
BOOT_INDEX9Boot priority index for the OpenCore boot media.
MEDIA_TYPEDevice type used for installation media.
USBnec-usb-xhci,id=xhciQEMU USB controller configuration.

๐ŸŽˆ Memory Ballooning

Also see Dynamic memory allocation for usage instructions and important caveats.

VariableDefaultDescription
BALLOONINGNEnables dynamic memory ballooning.
BALLOONING_MIN_MEM33%Minimum amount of memory retained by the VM.
BALLOONING_RAM_THRESHOLD80.0Host RAM usage percentage at which ballooning begins adjusting memory.
BALLOONING_RAM_THRESHOLD_HARD90.0Host RAM usage percentage at which ballooning becomes more aggressive.
BALLOONING_PSI_PRESSURE10.0PSI memory pressure level at which ballooning becomes more aggressive.
BALLOONING_PSI_PRESSURE_MAX50.0PSI memory pressure level at which ballooning reaches its strongest response.
BALLOONING_HYSTERESIS128MMinimum memory change before the balloon target is updated.
BALLOONING_KP0.5Proportional gain used by the ballooning controller.
BALLOONING_KI0.05Integral gain used by the ballooning controller.
BALLOONING_INTERVAL5Polling interval in seconds.
BALLOONING_DEBUGNEnables debug output for the ballooning monitor.

๐Ÿ”Œ Shutdown

VariableDefaultDescription
SHUTDOWNYEnables graceful ACPI shutdown.
TIMEOUT115Maximum time, in seconds, to wait before forcing macOS to stop.

๐Ÿž Debugging

VariableDefaultDescription
DEBUGNEnables verbose debug output.
TRACENEnables shell command tracing.
SERIALmon:stdioQEMU serial device configuration.
MONITORQEMU monitor configuration.
QMPQEMU Machine Protocol configuration.