22
33I needed a non-libvirt qemu driver, so this is it.
44
5+
6+ from @SvenDowideit
7+
58Its initial use is going to be for running the [ Rancher OS] ( https://github.com/rancher/os ) tests, but maybe you'll find a use for it too.
69
710
@@ -19,7 +22,16 @@ Options:
1922 - ` --qemu-boot2docker-url ` : The URL of the boot2docker image. Defaults to the latest available version.
2023 - ` --qemu-disk-size ` : Size of disk for the host in MB. Default: ` 20000 `
2124 - ` --qemu-memory ` : Size of memory for the host in MB. Default: ` 1024 `
22- - ` --qemu-network-bridge ` : Name of the virtual bridge to be used for networking. Default: ` virbr0 `
25+ - ` --qemu-cpu-count ` : Number of CPUs. Default: ` 1 `
26+ - ` --qemu-program ` : Name of the qemu program to run. Default: ` qemu-system-x86_64 `
27+ - ` --qemu-display ` : Show the graphical display output to the user. Default: false
28+ - ` --qemu-display-type ` : Select type of display to use (sdl/vnc=localhost:0/etc)
29+ - ` --qemu-nographic ` : Use -nographic instead of -display none. Default: false
30+ - ` --qemu-virtio-drives ` : Use virtio for drives (cdrom and disk). Default: false
31+ - ` --qemu-network ` : Networking to be used: user, tap or bridge. Default: ` user `
32+ - ` --qemu-network-interface ` : Name of the network interface to be used for networking. Default: ` tap0 `
33+ - ` --qemu-network-address ` : IP of the network address to be used for networking.
34+ - ` --qemu-network-bridge ` : Name of the network bridge to be used for networking. Default: ` br0 `
2335
2436The ` --qemu-boot2docker-url ` flag takes a few different forms. By
2537default, if no value is specified for this flag, Machine will check locally for
@@ -38,6 +50,14 @@ file://$HOME/Downloads/rc.iso` to test out a release candidate ISO that you have
3850downloaded already. You could also just get an ISO straight from the Internet
3951using the ` http:// ` form.
4052
53+ Note that when using virtio the drives will be mounted as ` /dev/vda ` and ` /dev/vdb ` ,
54+ instead of the usual ` /dev/cdrom ` and ` /dev/sda ` , since they are using paravirtualization.
55+
56+ If using the real network (tap or bridge), note that it needs a DHCP server running.
57+ The user network has it's own NAT network, which usually means it is running on 10.0.2.15
58+ Ultimately this driver should be able to query for IP, but for now the workaround is
59+ to use ` --qemu-network-address ` (and fixed addresses) until that feature is implemented.
60+
4161Environment variables:
4262
4363Here comes the list of the supported variables with the corresponding options. If both environment
@@ -46,3 +66,4 @@ variable and CLI option are provided the CLI option takes the precedence.
4666| Environment variable | CLI option |
4767| -----------------------------------| -----------------------------------|
4868| ` QEMU_BOOT2DOCKER_URL ` | ` --qemu-boot2docker-url ` |
69+ | ` QEMU_VIRTIO_DRIVES ` | ` --qemu-virtio-drives ` |
0 commit comments