Remove the docker-machine-driver-kvm2 wrapper and use the kvm driver as
internal driver.
To avoid dependency on libvirt shared library on Linux, we build now
with the libvirt_dlopen build tag. This is used only linux to avoid
linking with libvirt shared library. This is not documnted but can be
found in the source.
f7cdeba997/domain.go (L30)
With this we don't need libvirt devel libraries during build, and in
runtime we will fail if libvirt shared library is not installed.
With this change minikube can not be built for linux !amd64 since building
libvirt go binding requires CGO, and it does not work by changing GOARCH.
My editor is configured to remove trailing spaces automatically. Adding
as a separate commit to minimize the actual change and allow commit this
change separately from the kvm driver change.
* krunkit: Add krunkit driver
krunkit is a tool to launch configurable virtual machines using the
libkrun platform, optimized for GPU accelerated virtual machines and AI
workloads on Apple silicon.
It is mostly compatible with vfkit; the driver is a simplified copy of
the vfkit driver. Unlike vfkit, krunkit is available only on Apple
silicon.
Changes compared to vfkit driver:
- krunkit requires unix socket for networking, so we must use
vment-helper.
- krunkit does not support HardStop, so we kill it using SIGKILL.
- We must enable vmnet offloading, required for krunkit.
- The code was simplified since vmnet-helper is always used
- Code was cleaned up to use .ResolveStorePath()
- Unused Upgrade() function was removed
- Types and functions that should not be public made private
We require krunkit 0.2.2, supporting --restul-uri=unix://.
* reason: Make vment-helper error driver agnostic
Previously it was used only for vfkit, so we suggested to fallback to
the `nat` network. This advice is not relevant to krunkit or to qemu
(which can also use vmnet-helper).
Change the error to recommend installing vment-helper. We need to think
how we can recommend other networks for vfkit and qemu. Another solution
is to create error for every driver+network combination but this seems
hard to manage.
* hack: Add krunkit integration test
This is the same way that we test vfkit. This test is not running in the
CI.
Issues:
- Need to install and configure vment-helper (requires root).
* site: Add krunkit driver documentation
* Add new macOS vfkit driver, like hyperkit and qemu
It uses the new Virtualization.framework from macOS 11,
instead of the older Hypervisor.framework (hvf) in QEMU.
* Start vfkit in a new process group
* vfkit: Add firewall workaround from minikube
* vfkit: Add HostIP implementation for gateway
* vfkit: Add driver to extra-disks supported
* Add documentation for vfkit driver
* vfkit: Add usual integration tests
* Update site/content/en/docs/drivers/vfkit.md
Co-authored-by: Steven Powell <44844360+spowelljr@users.noreply.github.com>
---------
Co-authored-by: Nir Soffer <nsoffer@redhat.com>
Co-authored-by: Medya Ghazizadeh <medyagh@users.noreply.github.com>
Co-authored-by: Steven Powell <44844360+spowelljr@users.noreply.github.com>