Skip to content

Commit

Permalink
Handle registry auth from spec (#92)
Browse files Browse the repository at this point in the history
Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
  • Loading branch information
crazy-max and crazy-max authored Dec 19, 2020
1 parent 909866d commit a6ee528
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion internal/worker/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,9 @@ func (c *Client) Run() {
serviceUp.Spec.TaskTemplate.ForceUpdate = serviceUp.Version.Index

// Update service
response, err := c.Docker.Cli.ServiceUpdate(context.Background(), serviceUp.ID, serviceUp.Version, serviceUp.Spec, types.ServiceUpdateOptions{})
response, err := c.Docker.Cli.ServiceUpdate(context.Background(), serviceUp.ID, serviceUp.Version, serviceUp.Spec, types.ServiceUpdateOptions{
RegistryAuthFrom: types.RegistryAuthFromSpec,
})
if err != nil {
log.Error().Str("service", c.Job.Name).Err(err).Msg("Cannot update")
}
Expand Down

0 comments on commit a6ee528

Please sign in to comment.