diff --git a/builder/qemu/builder.go b/builder/qemu/builder.go index 43ec6b4c3..d2cda5d98 100644 --- a/builder/qemu/builder.go +++ b/builder/qemu/builder.go @@ -25,6 +25,7 @@ var accels = map[string]struct{}{ "kvm": {}, "tcg": {}, "xen": {}, + "hax": {}, } var netDevice = map[string]bool{ @@ -259,7 +260,7 @@ func (b *Builder) Prepare(raws ...interface{}) ([]string, error) { if _, ok := accels[b.config.Accelerator]; !ok { errs = packer.MultiErrorAppend( - errs, errors.New("invalid accelerator, only 'kvm', 'tcg', 'xen', or 'none' are allowed")) + errs, errors.New("invalid accelerator, only 'kvm', 'tcg', 'xen', 'hax', or 'none' are allowed")) } if _, ok := netDevice[b.config.NetDevice]; !ok { diff --git a/website/source/docs/builders/qemu.html.md b/website/source/docs/builders/qemu.html.md index f3de7cf9c..e57cc15bb 100644 --- a/website/source/docs/builders/qemu.html.md +++ b/website/source/docs/builders/qemu.html.md @@ -110,9 +110,9 @@ Linux server and have not enabled X11 forwarding (`ssh -X`). ### Optional: - `accelerator` (string) - The accelerator type to use when running the VM. - This may be `none`, `kvm`, `tcg`, or `xen`. The appropriate software must - already been installed on your build machine to use the accelerator you - specified. When no accelerator is specified, Packer will try to use `kvm` + This may be `none`, `kvm`, `tcg`, `hax`, or `xen`. The appropriate software + must have already been installed on your build machine to use the accelerator + you specified. When no accelerator is specified, Packer will try to use `kvm` if it is available but will default to `tcg` otherwise. - `boot_command` (array of strings) - This is an array of commands to type