vendor: github.com/moby/buildkit v0.21.0-rc1

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
This commit is contained in:
Jonathan A. Sternberg
2025-04-09 10:28:03 -05:00
parent a34cdff84e
commit 8fb1157b5f
221 changed files with 6530 additions and 3986 deletions

View File

@ -2,6 +2,7 @@ package workers
import (
"os"
"slices"
"strings"
)
@ -52,23 +53,14 @@ func (b backend) ExtraEnv() []string {
func (b backend) Supports(feature string) bool {
if enabledFeatures := os.Getenv("BUILDKIT_TEST_ENABLE_FEATURES"); enabledFeatures != "" {
for _, enabledFeature := range strings.Split(enabledFeatures, ",") {
if feature == enabledFeature {
return true
}
if slices.Contains(strings.Split(enabledFeatures, ","), feature) {
return true
}
}
if disabledFeatures := os.Getenv("BUILDKIT_TEST_DISABLE_FEATURES"); disabledFeatures != "" {
for _, disabledFeature := range strings.Split(disabledFeatures, ",") {
if feature == disabledFeature {
return false
}
}
}
for _, unsupportedFeature := range b.unsupportedFeatures {
if feature == unsupportedFeature {
if slices.Contains(strings.Split(disabledFeatures, ","), feature) {
return false
}
}
return true
return !slices.Contains(b.unsupportedFeatures, feature)
}

View File

@ -10,9 +10,9 @@ import (
"strings"
"time"
"github.com/docker/docker/client"
"github.com/moby/buildkit/cmd/buildkitd/config"
"github.com/moby/buildkit/util/testutil/dockerd"
"github.com/moby/buildkit/util/testutil/dockerd/client"
"github.com/moby/buildkit/util/testutil/integration"
"github.com/pkg/errors"
"golang.org/x/sync/errgroup"
@ -252,7 +252,7 @@ func waitForAPI(ctx context.Context, apiClient *client.Client, d time.Duration)
step := 50 * time.Millisecond
i := 0
for {
if _, err := apiClient.Ping(ctx); err == nil {
if err := apiClient.Ping(ctx); err == nil {
break
}
i++