KVM driver for docker-machine
This driver leverages the new plugin architecture being developed for Docker Machine.
GOGC=off go get -x -v github.com/rsampaio/docker-machine-kvm/cmd/docker-machine-driver-kvm
This driver leverages libvirt and the libvirt-go library to create and manage KVM based virtual machines. It has been tested with Ubuntu 12.04 through 15.04 and should work on most platforms with KVM/libvirt support. If you run into compatibility problems, please file an issue.
-
boot2docker.iso based images
-
Dual Network
- eth1 - A host private network called docker-machines is automatically created to ensure we always have connectivity to the VMs. The
docker-machine ip
command will always return this IP address which is only accessible from your local system. - eth0 - You can specify any libvirt named network. If you don't specify one, the "default" named network will be used.
- If you have exotic networking topolgies (openvswitch, etc.), you can use
virsh edit mymachinename
after creation, modify the first network definition by hand, then reboot the VM for the changes to take effect. - Typically this would be your "public" network accessible from external systems
- To retrieve the IP address of this network, you can run a command like the following:
docker-machine ssh mymachinename "ip -one -4 addr show dev eth0|cut -f7 -d' '"
- If you have exotic networking topolgies (openvswitch, etc.), you can use
- eth1 - A host private network called docker-machines is automatically created to ensure we always have connectivity to the VMs. The
-
Other Tunables
- Virtual CPU count via --kvm-cpu-count
- Disk size via --kvm-disk-size
- RAM via --kvm-memory