diff --git a/builder/parallels/common/hw_config.go b/builder/parallels/common/hw_config.go index 1f73f88ab..85f6d58b5 100644 --- a/builder/parallels/common/hw_config.go +++ b/builder/parallels/common/hw_config.go @@ -9,8 +9,8 @@ import ( type HWConfig struct { // cpu information - CpuCount int `mapstructure:"cpu_count"` - MemorySize int `mapstructure:"memory_size"` + CpuCount int `mapstructure:"cpus"` + MemorySize int `mapstructure:"memory"` // device presence Sound bool `mapstructure:"sound"` @@ -22,7 +22,7 @@ func (c *HWConfig) Prepare(ctx *interpolate.Context) []error { // Hardware and cpu options if c.CpuCount < 0 { - errs = append(errs, fmt.Errorf("An invalid cpu_count was specified (cpu_count < 0): %d", c.CpuCount)) + errs = append(errs, fmt.Errorf("An invalid number of cpus was specified (cpus < 0): %d", c.CpuCount)) c.CpuCount = 0 } if c.CpuCount == 0 { @@ -30,7 +30,7 @@ func (c *HWConfig) Prepare(ctx *interpolate.Context) []error { } if c.MemorySize < 0 { - errs = append(errs, fmt.Errorf("An invalid memory_size was specified (memory_size < 0): %d", c.MemorySize)) + errs = append(errs, fmt.Errorf("An invalid memory size was specified (memory < 0): %d", c.MemorySize)) c.MemorySize = 0 } if c.MemorySize == 0 { diff --git a/website/source/docs/builders/parallels-iso.html.md.erb b/website/source/docs/builders/parallels-iso.html.md.erb index afb086b1a..e66e4b7bf 100644 --- a/website/source/docs/builders/parallels-iso.html.md.erb +++ b/website/source/docs/builders/parallels-iso.html.md.erb @@ -102,7 +102,7 @@ builder. five seconds and one minute 30 seconds, respectively. If this isn't specified, the default is 10 seconds. -- `cpu_count` (number) - The number of cpus to use for building the VM. +- `cpus` (number) - The number of cpus to use for building the VM. Defaults to building with just one. - `disk_size` (number) - The size, in megabytes, of the hard disk to create @@ -176,7 +176,7 @@ builder. URLs must point to the same file (same checksum). By default this is empty and `iso_url` is used. Only one of `iso_url` or `iso_urls` can be specified. -- `memory_size` (number) - The amount of memory to use for building the VM in +- `memory` (number) - The amount of memory to use for building the VM in megabytes. Defaults to `512` megabytes. - `output_directory` (string) - This is the path to the directory where the