Volumes
Similar with Docker, Hyper allows you to mount additional volumes to a HyperVM instance. To do this, simply define the volumes to be attached in volumes
section, and reference the volume
in container
section:
The volumes
section is a list of items with the following properties:
name
: identifier of the volumesource
: the volume path on the host, either directory or file. If absent, a new 10GB volume will be createdformat
: the volume formatblock-device-image file:
raw
,qcow2
, this allows to mount a VM image to HyperVM. Note: the image file must have aEXT4
fs in it.plain file or dir:
vfs
, this options is to mount a file/dir on the host to to HyperVM instanceempty: leave empty
One volume can be mounted in multiple containers in a pod with different
path
andreadOnly
properties. Therefore, any data change in the volume will be visible across the entire Pod.
Last updated