mirror of
https://github.com/hashicorp/packer.git
synced 2026-04-24 07:37:22 -04:00
post-processor/digitalocean-import/post-processor.go: replace deprecated session.New() with session.NewSession()
This commit is contained in:
parent
ce674ff272
commit
db7a40d6ea
1 changed files with 4 additions and 1 deletions
|
|
@ -198,7 +198,10 @@ func (p *PostProcessor) PostProcess(ctx context.Context, ui packer.Ui, artifact
|
|||
logger: log.New(os.Stderr, "", log.LstdFlags),
|
||||
},
|
||||
}
|
||||
sess := session.New(spacesConfig)
|
||||
sess, err := session.NewSession(spacesConfig)
|
||||
if err != nil {
|
||||
return nil, false, false, err
|
||||
}
|
||||
|
||||
ui.Message(fmt.Sprintf("Uploading %s to spaces://%s/%s", source, p.config.SpaceName, p.config.ObjectName))
|
||||
err = uploadImageToSpaces(source, p, sess)
|
||||
|
|
|
|||
Loading…
Reference in a new issue