Skip to content

Commit

Permalink
Update for renames in Docker API v27
Browse files Browse the repository at this point in the history
  • Loading branch information
StevenMaude committed Sep 2, 2024
1 parent a908554 commit e5760d9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions pkg/builder/builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"regexp"
"strings"

"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/image"
"github.com/docker/docker/pkg/jsonmessage"
"github.com/sensiblecodeio/hookbot/pkg/listen"
"github.com/urfave/cli"
Expand Down Expand Up @@ -78,7 +78,7 @@ func Action(c *cli.Context) {

blankAuth := base64.URLEncoding.EncodeToString([]byte("{}"))

rc, err2 := client.ImagePush(context.TODO(), ref, types.ImagePushOptions{
rc, err2 := client.ImagePush(context.TODO(), ref, image.PushOptions{
RegistryAuth: blankAuth,
})
if err2 != nil {
Expand Down
3 changes: 2 additions & 1 deletion pkg/source/sources.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (

"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/container"
"github.com/docker/docker/api/types/image"
"github.com/docker/docker/api/types/network"
docker "github.com/docker/docker/client"
"github.com/docker/docker/pkg/archive"
Expand Down Expand Up @@ -84,7 +85,7 @@ func DockerPullSourceFromImage(image string) *DockerPullSource {
func (s *DockerPullSource) Obtain(c *docker.Client, payload []byte) (string, error) {
imageName := fmt.Sprintf("%s:%s", s.Repository, s.Tag)

rc, err := c.ImagePull(context.TODO(), imageName, types.ImagePullOptions{})
rc, err := c.ImagePull(context.TODO(), imageName, image.PullOptions{})
if err != nil {
return "", err
}
Expand Down

0 comments on commit e5760d9

Please sign in to comment.