|
| 1 | +# <a name="VirtualMachineSpecificContainerConfiguration" /> Virtual-machine-specific Container Configuration |
| 2 | + |
| 3 | +This section describes the schema for the [virtual-machine-specific section](config.md#platform-specific-configuration) of the [container configuration](config.md). |
| 4 | +The virtual-machine container specification provides additional configuration for the hypervisor, kernel, and image. |
| 5 | + |
| 6 | +## <a name="HypervisorObject" /> Hypervisor Object |
| 7 | + |
| 8 | +**`hypervisor`** (object, OPTIONAL) specifies details of the hypervisor that manages the container virtual machine. |
| 9 | +* **`path`** (string, REQUIRED) path to the hypervisor binary that manages the container virtual machine. |
| 10 | + This value MUST be an absolute path in the [runtime mount namespace](glossary.md#runtime-namespace). |
| 11 | +* **`parameters`** (array of strings, OPTIONAL) specifies an array of parameters to pass to the hypervisor. |
| 12 | + |
| 13 | +### Example |
| 14 | + |
| 15 | +```json |
| 16 | + "hypervisor": { |
| 17 | + "path": "/path/to/vmm", |
| 18 | + "parameters": ["opts1=foo", "opts2=bar"] |
| 19 | + } |
| 20 | +``` |
| 21 | + |
| 22 | +## <a name="KernelObject" /> Kernel Object |
| 23 | + |
| 24 | +**`kernel`** (object, REQUIRED) specifies details of the kernel to boot the container virtual machine with. |
| 25 | +* **`path`** (string, REQUIRED) path to the kernel used to boot the container virtual machine. |
| 26 | + This value MUST be an absolute path in the [runtime mount namespace](glossary.md#runtime-namespace). |
| 27 | +* **`parameters`** (array of strings, OPTIONAL) specifies an array of parameters to pass to the kernel. |
| 28 | +* **`initrd`** (string, OPTIONAL) path to an initial ramdisk to be used by the container virtual machine. |
| 29 | + This value MUST be an absolute path in the [runtime mount namespace](glossary.md#runtime-namespace). |
| 30 | + |
| 31 | +### Example |
| 32 | + |
| 33 | +```json |
| 34 | + "kernel": { |
| 35 | + "path": "/path/to/vmlinuz", |
| 36 | + "parameters": ["foo=bar", "hello world"], |
| 37 | + "initrd": "/path/to/initrd.img" |
| 38 | + } |
| 39 | +``` |
| 40 | + |
| 41 | +## <a name="ImageObject" /> Image Object |
| 42 | + |
| 43 | +**`image`** (object, OPTIONAL) specifies details of the image that contains the root filesystem for the container virtual machine. |
| 44 | +* **`path`** (string, REQUIRED) path to the container virtual machine root image. |
| 45 | + This value MUST be an absolute path in the [runtime mount namespace](glossary.md#runtime-namespace). |
| 46 | +* **`type`** (string, REQUIRED) type of the container virtual machine root image. The following disk image formats are supported: |
| 47 | + * **`raw`** raw disk image format. Unset values for `type` will default to that format. |
| 48 | + * **`qcow2`** QEMU image format. |
| 49 | + * **`qcow`** Old QEMU image format. |
| 50 | + * **`vdi`** VirtualBox 1.1 compatible image format. |
| 51 | + * **`vmdk`** VMware compatible image format. |
| 52 | + * **`vhd`** Virtual Hard Disk image format. |
| 53 | + |
| 54 | + This image contains the root filesystem that the virtual machine **`kernel`** will boot into, not to be confused with the container root filesystem itself. The latter, as specified by **`path`** from the [Root Configuration](config.md#Root-Configuration) section, will be mounted inside the virtual machine at a location chosen by the virtual-machine-based runtime. |
| 55 | + |
| 56 | +### Example |
| 57 | + |
| 58 | +```json |
| 59 | + "image": { |
| 60 | + "path": "/path/to/vm/rootfs.img", |
| 61 | + "type": "raw" |
| 62 | + } |
| 63 | +``` |
0 commit comments