builder/openstack: Fix dropped error

This commit is contained in:
Lars Lehtonen 2019-09-16 06:26:56 -07:00
parent 4d4bd38afa
commit 6c1ce2bd9a
1 changed files with 6 additions and 0 deletions

View File

@ -40,6 +40,12 @@ func (s *StepSourceImageInfo) Run(ctx context.Context, state multistep.StateBag)
}
client, err := config.imageV2Client()
if err != nil {
err := fmt.Errorf("error creating image client: %s", err)
state.Put("error", err)
ui.Error(err.Error())
return multistep.ActionHalt
}
if s.SourceImageName != "" {
s.SourceImageOpts = images.ListOpts{