Remove changes that will be part of another pull request
This commit is contained in:
parent
1e4b5dd51b
commit
9161285470
@ -33,8 +33,6 @@ type Config struct {
|
|||||||
InstallTimeout time.Duration ``
|
InstallTimeout time.Duration ``
|
||||||
SourcePath string `mapstructure:"source_path"`
|
SourcePath string `mapstructure:"source_path"`
|
||||||
|
|
||||||
Firmware string `mapstructure:"firmware"`
|
|
||||||
|
|
||||||
ctx interpolate.Context
|
ctx interpolate.Context
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -107,7 +107,6 @@ type FlatConfig struct {
|
|||||||
PlatformArgs map[string]string `mapstructure:"platform_args" cty:"platform_args" hcl:"platform_args"`
|
PlatformArgs map[string]string `mapstructure:"platform_args" cty:"platform_args" hcl:"platform_args"`
|
||||||
RawInstallTimeout *string `mapstructure:"install_timeout" cty:"install_timeout" hcl:"install_timeout"`
|
RawInstallTimeout *string `mapstructure:"install_timeout" cty:"install_timeout" hcl:"install_timeout"`
|
||||||
SourcePath *string `mapstructure:"source_path" cty:"source_path" hcl:"source_path"`
|
SourcePath *string `mapstructure:"source_path" cty:"source_path" hcl:"source_path"`
|
||||||
Firmware *string `mapstructure:"firmware" cty:"firmware" hcl:"firmware"`
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// FlatMapstructure returns a new FlatConfig.
|
// FlatMapstructure returns a new FlatConfig.
|
||||||
@ -219,7 +218,6 @@ func (*FlatConfig) HCL2Spec() map[string]hcldec.Spec {
|
|||||||
"platform_args": &hcldec.AttrSpec{Name: "platform_args", Type: cty.Map(cty.String), Required: false},
|
"platform_args": &hcldec.AttrSpec{Name: "platform_args", Type: cty.Map(cty.String), Required: false},
|
||||||
"install_timeout": &hcldec.AttrSpec{Name: "install_timeout", Type: cty.String, Required: false},
|
"install_timeout": &hcldec.AttrSpec{Name: "install_timeout", Type: cty.String, Required: false},
|
||||||
"source_path": &hcldec.AttrSpec{Name: "source_path", Type: cty.String, Required: false},
|
"source_path": &hcldec.AttrSpec{Name: "source_path", Type: cty.String, Required: false},
|
||||||
"firmware": &hcldec.AttrSpec{Name: "firmware", Type: cty.String, Required: false},
|
|
||||||
}
|
}
|
||||||
return s
|
return s
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,6 @@ func (self *StepStartVmPaused) Run(ctx context.Context, state multistep.StateBag
|
|||||||
|
|
||||||
c := state.Get("client").(*Connection)
|
c := state.Get("client").(*Connection)
|
||||||
ui := state.Get("ui").(packer.Ui)
|
ui := state.Get("ui").(packer.Ui)
|
||||||
config := state.Get("config").(Config)
|
|
||||||
|
|
||||||
ui.Say("Step: Start VM Paused")
|
ui.Say("Step: Start VM Paused")
|
||||||
|
|
||||||
@ -35,7 +34,7 @@ func (self *StepStartVmPaused) Run(ctx context.Context, state multistep.StateBag
|
|||||||
return multistep.ActionHalt
|
return multistep.ActionHalt
|
||||||
}
|
}
|
||||||
|
|
||||||
err = c.client.VM.SetHVMBootParams(c.session, instance, map[string]string{"order": "cd", "firmware": config.Firmware})
|
err = c.client.VM.SetHVMBootParams(c.session, instance, map[string]string{"order": "cd"})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
ui.Error(fmt.Sprintf("Unable to set HVM boot params: %s", err.Error()))
|
ui.Error(fmt.Sprintf("Unable to set HVM boot params: %s", err.Error()))
|
||||||
return multistep.ActionHalt
|
return multistep.ActionHalt
|
||||||
|
@ -77,10 +77,6 @@ func (self *Builder) Prepare(raws ...interface{}) (params []string, warns []stri
|
|||||||
self.config.CloneTemplate = "Other install media"
|
self.config.CloneTemplate = "Other install media"
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.config.Firmware == "" {
|
|
||||||
self.config.Firmware = "bios"
|
|
||||||
}
|
|
||||||
|
|
||||||
if len(self.config.PlatformArgs) == 0 {
|
if len(self.config.PlatformArgs) == 0 {
|
||||||
pargs := make(map[string]string)
|
pargs := make(map[string]string)
|
||||||
pargs["viridian"] = "false"
|
pargs["viridian"] = "false"
|
||||||
|
Loading…
Reference in New Issue
Block a user