vSphere ISO supports more common options (#8845)

The `convert_to_template` and `create_snapshot` are supported across
both builders, but currently only shown in the vSphere Clone docs, this adds
them to it.
This commit is contained in:
Wilken Rivera 2020-03-05 15:04:15 -05:00 committed by GitHub
parent 7e382d0df7
commit 698924f246
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,4 @@
//go:generate struct-markdown
//go:generate mapstructure-to-hcl2 -type Config
package iso
@ -33,7 +34,10 @@ type Config struct {
common.ShutdownConfig `mapstructure:",squash"`
CreateSnapshot bool `mapstructure:"create_snapshot"`
// Create a snapshot when set to `true`, so the VM can be used as a base
// for linked clones. Defaults to `false`.
CreateSnapshot bool `mapstructure:"create_snapshot"`
// Convert VM to a template. Defaults to `false`.
ConvertToTemplate bool `mapstructure:"convert_to_template"`
ctx interpolate.Context

View File

@ -43,6 +43,8 @@ references for [ISO](#iso-configuration),
configuration references, which are
necessary for this build to succeed and can be found further down the page.
<%= partial "partials/builder/vsphere/iso/Config-not-required" %>
### Connection Configuration
<%= partial "partials/builder/vsphere/common/ConnectConfig-not-required" %>

View File

@ -0,0 +1,7 @@
<!-- Code generated from the comments of the Config struct in builder/vsphere/iso/config.go; DO NOT EDIT MANUALLY -->
- `create_snapshot` (bool) - Create a snapshot when set to `true`, so the VM can be used as a base
for linked clones. Defaults to `false`.
- `convert_to_template` (bool) - Convert VM to a template. Defaults to `false`.