jakobadam / packer-qemu-templates

Packer qemu templates
Mozilla Public License 2.0
333 stars 174 forks source link

adding headless building #13

Closed kevit closed 7 years ago

kevit commented 8 years ago

Basically if you run packer build remotely, you will get an error like

==> ubuntu-1604-server-vagrant: Error launching VM: Qemu failed to start. Please run with logs to get more info.
==> ubuntu-1604-server-vagrant: Deleting output directory...
Build 'ubuntu-1604-server-vagrant' errored: Build was halted.

I propose to add headless configuration option

jakobadam commented 8 years ago

Sure. Can you add it as a variable?

"headless": "{{ user `headless` }}",

And default to not being headless.

jakobadam commented 7 years ago

Fixed in cae3cff9642afb09a87e7e7e49d1d59a47914ff9. Now you can set it like this:

packer build -var-file=ubuntu1604.json -var headless=true ubuntu.json