From 662d5a3b2920a787b7bc6775ce406fc83a5cbe05 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 9 Nov 2025 15:05:59 +0000 Subject: [PATCH] chore(deps): bump github.com/moby/buildkit from 0.23.2 to 0.25.1 Bumps [github.com/moby/buildkit](https://github.com/moby/buildkit) from 0.23.2 to 0.25.1. - [Release notes](https://github.com/moby/buildkit/releases) - [Commits](https://github.com/moby/buildkit/compare/v0.23.2...v0.25.1) --- updated-dependencies: - dependency-name: github.com/moby/buildkit dependency-version: 0.25.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 8 ++--- .../dockerfile/instructions/commands.go | 2 +- .../instructions/exclude_pattern_feature.go | 7 ----- .../frontend/dockerfile/instructions/parse.go | 31 +++++++++---------- .../frontend/dockerfile/linter/ruleset.go | 18 +++++++++++ .../moby/buildkit/util/stack/stack.pb.go | 2 +- vendor/modules.txt | 4 +-- 8 files changed, 41 insertions(+), 33 deletions(-) delete mode 100644 vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/exclude_pattern_feature.go diff --git a/go.mod b/go.mod index b4f76106..e8cea6dc 100644 --- a/go.mod +++ b/go.mod @@ -24,7 +24,7 @@ require ( github.com/jedib0t/go-pretty/v6 v6.6.8 github.com/matcornic/hermes/v2 v2.1.0 github.com/microcosm-cc/bluemonday v1.0.27 - github.com/moby/buildkit v0.23.2 + github.com/moby/buildkit v0.25.2 github.com/nlopes/slack v0.6.0 github.com/opencontainers/go-digest v1.0.0 github.com/opencontainers/image-spec v1.1.1 diff --git a/go.sum b/go.sum index 6890b993..d15f4c49 100644 --- a/go.sum +++ b/go.sum @@ -84,8 +84,8 @@ github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1 github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5QvfrDyIgxBk= github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= -github.com/docker/cli v28.3.3+incompatible h1:fp9ZHAr1WWPGdIWBM1b3zLtgCF+83gRdVMTJsUeiyAo= -github.com/docker/cli v28.3.3+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/cli v28.4.0+incompatible h1:RBcf3Kjw2pMtwui5V0DIMdyeab8glEw5QY0UUU4C9kY= +github.com/docker/cli v28.4.0+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.3+incompatible h1:AtKxIZ36LoNK51+Z6RpzLpddBirtxJnzDrHLEKxTAYk= github.com/docker/distribution v2.8.3+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/docker v28.5.2+incompatible h1:DBX0Y0zAjZbSrm1uzOkdr1onVghKaftjlSWt4AFexzM= @@ -240,8 +240,8 @@ github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/moby/buildkit v0.23.2 h1:gt/dkfcpgTXKx+B9I310kV767hhVqTvEyxGgI3mqsGQ= -github.com/moby/buildkit v0.23.2/go.mod h1:iEjAfPQKIuO+8y6OcInInvzqTMiKMbb2RdJz1K/95a0= +github.com/moby/buildkit v0.25.2 h1:mReLKDPv05cqk6o/u3ixq2/iTsWGHoUO5Zg3lojrQTk= +github.com/moby/buildkit v0.25.2/go.mod h1:phM8sdqnvgK2y1dPDnbwI6veUCXHOZ6KFSl6E164tkc= github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= github.com/moby/sys/atomicwriter v0.1.0 h1:kw5D/EqkBwsBFi0ss9v1VG3wIkVhzGvLklJ+w3A14Sw= diff --git a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/commands.go b/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/commands.go index f82f07f9..cef213ab 100644 --- a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/commands.go +++ b/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/commands.go @@ -244,7 +244,7 @@ type AddCommand struct { Chmod string Link bool ExcludePatterns []string - KeepGitDir bool // whether to keep .git dir, only meaningful for git sources + KeepGitDir *bool // whether to keep .git dir, only meaningful for git sources Checksum string Unpack *bool } diff --git a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/exclude_pattern_feature.go b/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/exclude_pattern_feature.go deleted file mode 100644 index a1a7342f..00000000 --- a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/exclude_pattern_feature.go +++ /dev/null @@ -1,7 +0,0 @@ -//go:build dfexcludepatterns - -package instructions - -func init() { - excludePatternsEnabled = true -} diff --git a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/parse.go b/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/parse.go index ccb0820f..20b93d05 100644 --- a/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/parse.go +++ b/vendor/github.com/moby/buildkit/frontend/dockerfile/instructions/parse.go @@ -20,8 +20,6 @@ import ( "github.com/pkg/errors" ) -var excludePatternsEnabled = false - type parseRequest struct { command string args []string @@ -33,8 +31,10 @@ type parseRequest struct { comments []string } -var parseRunPreHooks []func(*RunCommand, parseRequest) error -var parseRunPostHooks []func(*RunCommand, parseRequest) error +var ( + parseRunPreHooks []func(*RunCommand, parseRequest) error + parseRunPostHooks []func(*RunCommand, parseRequest) error +) var parentsEnabled = false @@ -326,19 +326,13 @@ func parseAdd(req parseRequest) (*AddCommand, error) { return nil, errNoDestinationArgument("ADD") } - var flExcludes *Flag - - // silently ignore if not -labs - if excludePatternsEnabled { - flExcludes = req.flags.AddStrings("exclude") - } - flChown := req.flags.AddString("chown", "") flChmod := req.flags.AddString("chmod", "") flLink := req.flags.AddBool("link", false) flKeepGitDir := req.flags.AddBool("keep-git-dir", false) flChecksum := req.flags.AddString("checksum", "") flUnpack := req.flags.AddBool("unpack", false) + flExcludes := req.flags.AddStrings("exclude") if err := req.flags.Parse(); err != nil { return nil, err } @@ -354,13 +348,19 @@ func parseAdd(req parseRequest) (*AddCommand, error) { unpack = &b } + var keepGit *bool + if _, ok := req.flags.used["keep-git-dir"]; ok { + b := flKeepGitDir.Value == "true" + keepGit = &b + } + return &AddCommand{ withNameAndCode: newWithNameAndCode(req), SourcesAndDest: *sourcesAndDest, Chown: flChown.Value, Chmod: flChmod.Value, Link: flLink.Value == "true", - KeepGitDir: flKeepGitDir.Value == "true", + KeepGitDir: keepGit, Checksum: flChecksum.Value, ExcludePatterns: stringValuesFromFlagIfPossible(flExcludes), Unpack: unpack, @@ -372,12 +372,7 @@ func parseCopy(req parseRequest) (*CopyCommand, error) { return nil, errNoDestinationArgument("COPY") } - var flExcludes *Flag var flParents *Flag - - if excludePatternsEnabled { - flExcludes = req.flags.AddStrings("exclude") - } if parentsEnabled { flParents = req.flags.AddBool("parents", false) } @@ -386,6 +381,7 @@ func parseCopy(req parseRequest) (*CopyCommand, error) { flFrom := req.flags.AddString("from", "") flChmod := req.flags.AddString("chmod", "") flLink := req.flags.AddBool("link", false) + flExcludes := req.flags.AddStrings("exclude") if err := req.flags.Parse(); err != nil { return nil, err @@ -596,6 +592,7 @@ func parseOptInterval(f *Flag) (time.Duration, error) { } return d, nil } + func parseHealthcheck(req parseRequest) (*HealthCheckCommand, error) { if len(req.args) == 0 { return nil, errAtLeastOneArgument("HEALTHCHECK") diff --git a/vendor/github.com/moby/buildkit/frontend/dockerfile/linter/ruleset.go b/vendor/github.com/moby/buildkit/frontend/dockerfile/linter/ruleset.go index 63cc0013..7a94c76a 100644 --- a/vendor/github.com/moby/buildkit/frontend/dockerfile/linter/ruleset.go +++ b/vendor/github.com/moby/buildkit/frontend/dockerfile/linter/ruleset.go @@ -174,4 +174,22 @@ var ( }, Experimental: true, } + RuleExposeProtoCasing = LinterRule[func(string) string]{ + Name: "ExposeProtoCasing", + Description: "Protocol in EXPOSE instruction should be lowercase", + URL: "https://docs.docker.com/go/dockerfile/rule/expose-proto-casing/", + Format: func(port string) string { + return fmt.Sprintf("Defined protocol '%s' in EXPOSE instruction should be lowercase", port) + }, + } + RuleExposeInvalidFormat = LinterRule[func(string) string]{ + Name: "ExposeInvalidFormat", + Description: "IP address and host-port mapping should not be used in EXPOSE instruction. This will become an error in a future release", + URL: "https://docs.docker.com/go/dockerfile/rule/expose-invalid-format/", + Format: func(port string) string { + return fmt.Sprintf("EXPOSE instruction should not define an IP address or host-port mapping, found '%s'", port) + }, + // TODO(crazy-max): deprecate this rule in the future and error out instead + // Deprecated: true, + } ) diff --git a/vendor/github.com/moby/buildkit/util/stack/stack.pb.go b/vendor/github.com/moby/buildkit/util/stack/stack.pb.go index ef36670a..5e9ef189 100644 --- a/vendor/github.com/moby/buildkit/util/stack/stack.pb.go +++ b/vendor/github.com/moby/buildkit/util/stack/stack.pb.go @@ -1,6 +1,6 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.36.6 +// protoc-gen-go v1.36.9 // protoc v3.11.4 // source: github.com/moby/buildkit/util/stack/stack.proto diff --git a/vendor/modules.txt b/vendor/modules.txt index 2b76fe5a..901aa96f 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -305,8 +305,8 @@ github.com/mitchellh/go-homedir # github.com/mitchellh/mapstructure v1.5.0 ## explicit; go 1.14 github.com/mitchellh/mapstructure -# github.com/moby/buildkit v0.23.2 -## explicit; go 1.23.0 +# github.com/moby/buildkit v0.25.2 +## explicit; go 1.24.0 github.com/moby/buildkit/frontend/dockerfile/command github.com/moby/buildkit/frontend/dockerfile/instructions github.com/moby/buildkit/frontend/dockerfile/linter