vsphere/iso: Add support for ovf export options

* Fix generated documentation for the additional export options field
This commit is contained in:
Wilken Rivera 2020-03-19 14:46:30 -04:00
parent 56aebbeda9
commit a7c5daf80d
3 changed files with 11 additions and 2 deletions

View file

@ -64,7 +64,7 @@ type ExportConfig struct {
// * nodevicesubtypes - resource subtypes for CD/DVD drives, floppy drives, and serial and parallel ports are not exported
//
// For example, adding the following export config option would output the mac addresses for all Ethernet devices in the ovf file:
//
// ```json
// ...
// "export": {

View file

@ -139,6 +139,7 @@ func (b *Builder) Run(ctx context.Context, ui packer.Ui, hook packer.Hook) (pack
Images: b.config.Export.Images,
Manifest: b.config.Export.Manifest,
OutputDir: b.config.Export.OutputDir.OutputDir,
Options: b.config.Export.Options,
})
}

View file

@ -8,7 +8,15 @@
- `manifest` (string) - generate manifest using sha1, sha256, sha512. Defaults to 'sha256'. Use 'none' for no manifest.
- `options` ([]string) - ```json
- `options` ([]string) - Advanced ovf export options. Options can include:
* mac - MAC address is exported for all ethernet devices
* uuid - UUID is exported for all virtual machines
* extraconfig - all extra configuration options are exported for a virtual machine
* nodevicesubtypes - resource subtypes for CD/DVD drives, floppy drives, and serial and parallel ports are not exported
For example, adding the following export config option would output the mac addresses for all Ethernet devices in the ovf file:
```json
...
"export": {
"options": ["mac"]