add physical disk mounts with native VZ backend - #1592
Conversation
|
Native VZ backend progress update:
Validation run locally:
Native VZ live E2E status:
|
|
Final VZ validation update: Native VZ physical disk smoke passed with:
Observed evidence from the smoke run:
Final local gates after the VZ+NFS state-dir fix:
Cleanup audit is clean after the smoke run: no matching hdiutil attachment, no |
Signed-off-by: Ton Sharp <45160296+66Ton99@users.noreply.github.com>
Signed-off-by: Ton Sharp <45160296+66Ton99@users.noreply.github.com>
Signed-off-by: Ton Sharp <45160296+66Ton99@users.noreply.github.com>
Signed-off-by: Ton Sharp <45160296+66Ton99@users.noreply.github.com>
1e3d222 to
59cc4a1
Compare
|
Amazing work, thank you! What is needed before review and merging? |
|
|
What changed
physicalDisksprofile configuration for macOS physical partitions.physicalDisks[].backendvaluesauto,nbd, andvz;autostays conservative and resolves tonbd.qemu-nbd, an SSH tunnel, guest/dev/nbdN, and Linux filesystem mounting.vmType: vzby emitting LimablockDevicesand mounting the stable guest path/dev/disk/by-id/virtio-<device>.colima startflag merges.scripts/physical_disk_vz_e2e.shfor repeatable native VZ smoke coverage with a temporary ext4 disk image surrogate.Notes
backend: vzrequiresvmType: vz, macOS 14 or newer, and a Lima build that exposes secure--block-devicesupport in bothlimactl create --helpandlimactl sudoers --help. If those requirements are not met, Colima rejects the config before startup instead of falling back silently.Host-side sudo is limited to root-only macOS operations. With
backend: nbd, that means opening the raw partition withqemu-nbd, mounting/unmounting the NFS export, and cleaning up root-ownedqemu-nbd. Withbackend: vz, Lima handles the privileged disk open through its VZ block-device helper during VM startup, and Colima still uses host sudo only for the optional macOS NFS mount/unmount. Guest filesystem setup uses sudo inside the VM.Validation
go test ./...go build -o /tmp/colima-vz-physical ./cmd/colimabash -n scripts/physical_disk_vz_e2e.shgit diff --check/dev/disk4s1//dev/rdisk4s1, mounted in the VM as/dev/nbd0, exported through NFSv4, and verified read/write in both directions./tmp/lima-5117/_output/bin/limactlrebuilt asv2.2.0with secure--block-devicesupport:/mnt/colima/physical/smoke /dev/vdb ext4 rw,relatime./dev/disk/by-id/virtio-disk4s1 ... TYPE="ext4"./Volumes/Colima/physical-vz-e2e*mount, no/private/etc/sudoers.d/colima-vz-e2e, no/opt/colima-vz-e2e, nophysical-vz-e2eLima instance, and no stalecolima-physical-vz-e2e-*/ssh.sockmux process.