newsnowlabs / runcvm

RunCVM (Run Container VM) is an experimental open-source Docker container runtime, for launching standard container workloads - as well as Systemd, Docker, even OpenWrt - in VMs using 'docker run`
Apache License 2.0
72 stars 4 forks source link

Add support for booting from file-backed disk #12

Open struanb opened 8 months ago

struanb commented 8 months ago

Currently RunCVM boots from a virtiofs-mounted root filesystems, which is highly flexible and space-efficient and reasonably performant, but not as performant as a file-backed disk.

RunCVM supports mounting file-backed disks but not for the root filesystem.

If feasible, provide an option to enable this.

struanb commented 3 months ago

Worth noting that the latest RUNCVM_DISKS environment variable behaviour, which mounts a file-backed virtual disk populated with any pre-existing image contents at almost any desired filesystem location (except, currently, /) will provide much better VM disk performance in a range of scenarios where these can be effectively used.

For example, if the booted system is itself primarily running applications within Docker, mounting a single virtual disk at /var/lib/docker should be sufficient to deliver high disk performance.