From 0598eeb0f2474fe6437295f0318f6f98c7b87656 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 Jan 2024 14:34:31 +0100 Subject: [PATCH] chore(deps): bump github.com/docker/compose/v2 from 2.23.3 to 2.24.0 in /modules/compose (#2096) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore(deps): bump github.com/docker/compose/v2 in /modules/compose Bumps [github.com/docker/compose/v2](https://github.com/docker/compose) from 2.23.3 to 2.24.0. - [Release notes](https://github.com/docker/compose/releases) - [Commits](https://github.com/docker/compose/compare/v2.23.3...v2.24.0) --- updated-dependencies: - dependency-name: github.com/docker/compose/v2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * chore: bump buildx to rc-2 * chore: use compose-go v2 * fix: resolve breaking changes using the right type Compose's services is now a map from string to ServiceConfig, so we are updating the code to lookup the services using the map instead of the string. * fix: use non-deprecated list options * chore: proper deprecation commands for LocalDockerCompose * chore: use require for Up errors * chore: fix validation for modern compose version * chore: remove unused variable * chore: remove named return * chore: simplify * chore: use non-deprecated options * chore: resolve golangci lints * fix: assert.Len * fix: wrong replace * chore: bump compose dependencies * fix: honour compose unicity * fix: lint applied reversely * fix: length * fix: wrong copy&paste --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Manuel de la Peña --- .github/workflows/ci-test-go.yml | 2 +- modules/compose/compose.go | 16 +- modules/compose/compose_api.go | 20 +-- modules/compose/compose_api_test.go | 152 +++++++++--------- modules/compose/compose_local.go | 8 +- modules/compose/compose_test.go | 33 ++-- modules/compose/go.mod | 43 +++-- modules/compose/go.sum | 105 ++++++------ .../testdata/docker-compose-override.yml | 5 - .../testdata/docker-compose-simple.yml | 1 + 10 files changed, 200 insertions(+), 185 deletions(-) diff --git a/.github/workflows/ci-test-go.yml b/.github/workflows/ci-test-go.yml index 97cbdee663..2b31e6f435 100644 --- a/.github/workflows/ci-test-go.yml +++ b/.github/workflows/ci-test-go.yml @@ -71,7 +71,7 @@ jobs: - name: golangci-lint # TODO: Remove each example/module once it passes the golangci-lint - if: ${{ inputs.platform == 'ubuntu-latest' && inputs.go-version == '1.20.x' && !contains(fromJSON('["modules/compose"]'), inputs.project-directory) }} + if: ${{ inputs.platform == 'ubuntu-latest' && inputs.go-version == '1.20.x' }} uses: golangci/golangci-lint-action@3a919529898de77ec3da873e3063ca4b10e7f5cc # v3 with: # Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version diff --git a/modules/compose/compose.go b/modules/compose/compose.go index dfb9d61a10..75bf55e0aa 100644 --- a/modules/compose/compose.go +++ b/modules/compose/compose.go @@ -6,9 +6,8 @@ import ( "path/filepath" "runtime" "strings" - "sync" - "github.com/compose-spec/compose-go/types" + "github.com/compose-spec/compose-go/v2/types" "github.com/docker/cli/cli/command" "github.com/docker/cli/cli/flags" "github.com/docker/compose/v2/pkg/api" @@ -24,10 +23,7 @@ const ( envComposeFile = "COMPOSE_FILE" ) -var ( - composeLogOnce sync.Once - ErrNoStackConfigured = errors.New("no stack files configured") -) +var ErrNoStackConfigured = errors.New("no stack files configured") type composeStackOptions struct { Identifier string @@ -77,9 +73,9 @@ type ComposeStack interface { ServiceContainer(ctx context.Context, svcName string) (*testcontainers.DockerContainer, error) } -// DockerCompose defines the contract for running Docker Compose // Deprecated: DockerCompose is the old shell escape based API // use ComposeStack instead +// DockerCompose defines the contract for running Docker Compose type DockerCompose interface { Down() ExecError Invoke() ExecError @@ -138,6 +134,9 @@ func NewDockerComposeWith(opts ...ComposeStackOption) (*dockerCompose, error) { return composeAPI, nil } +// Deprecated: NewLocalDockerCompose returns a DockerCompose compatible instance which is superseded +// by ComposeStack use NewDockerCompose instead to get a ComposeStack compatible instance +// // NewLocalDockerCompose returns an instance of the local Docker Compose, using an // array of Docker Compose file paths and an identifier for the Compose execution. // @@ -145,9 +144,6 @@ func NewDockerComposeWith(opts ...ComposeStackOption) (*dockerCompose, error) { // Docker Compose execution. The identifier represents the name of the execution, // which will define the name of the underlying Docker network and the name of the // running Compose services. -// -// Deprecated: NewLocalDockerCompose returns a DockerCompose compatible instance which is superseded -// by ComposeStack use NewDockerCompose instead to get a ComposeStack compatible instance func NewLocalDockerCompose(filePaths []string, identifier string, opts ...LocalDockerComposeOption) *LocalDockerCompose { dc := &LocalDockerCompose{ LocalDockerComposeOptions: &LocalDockerComposeOptions{ diff --git a/modules/compose/compose_api.go b/modules/compose/compose_api.go index bf336ba97c..70bc071897 100644 --- a/modules/compose/compose_api.go +++ b/modules/compose/compose_api.go @@ -7,11 +7,11 @@ import ( "strings" "sync" - "github.com/compose-spec/compose-go/cli" - "github.com/compose-spec/compose-go/types" + "github.com/compose-spec/compose-go/v2/cli" + "github.com/compose-spec/compose-go/v2/types" "github.com/docker/cli/cli/command" "github.com/docker/compose/v2/pkg/api" - types2 "github.com/docker/docker/api/types" + "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/client" "golang.org/x/sync/errgroup" @@ -180,10 +180,12 @@ func (d *dockerCompose) Down(ctx context.Context, opts ...StackDownOption) error return d.composeService.Down(ctx, d.name, options.DownOptions) } -func (d *dockerCompose) Up(ctx context.Context, opts ...StackUpOption) (err error) { +func (d *dockerCompose) Up(ctx context.Context, opts ...StackUpOption) error { d.lock.Lock() defer d.lock.Unlock() + var err error + d.project, err = d.compileProject() if err != nil { return err @@ -203,11 +205,11 @@ func (d *dockerCompose) Up(ctx context.Context, opts ...StackUpOption) (err erro if len(upOptions.Services) != len(d.project.Services) { sort.Strings(upOptions.Services) - filteredServices := make(types.Services, 0, len(d.project.Services)) + filteredServices := types.Services{} - for i := range d.project.Services { - if idx := sort.SearchStrings(upOptions.Services, d.project.Services[i].Name); idx < len(upOptions.Services) && upOptions.Services[idx] == d.project.Services[i].Name { - filteredServices = append(filteredServices, d.project.Services[i]) + for _, srv := range upOptions.Services { + if srvConfig, ok := d.project.Services[srv]; ok { + filteredServices[srv] = srvConfig } } @@ -288,7 +290,7 @@ func (d *dockerCompose) lookupContainer(ctx context.Context, svcName string) (*t return container, nil } - listOptions := types2.ContainerListOptions{ + listOptions := container.ListOptions{ All: true, Filters: filters.NewArgs( filters.Arg("label", fmt.Sprintf("%s=%s", api.ProjectLabel, d.name)), diff --git a/modules/compose/compose_api_test.go b/modules/compose/compose_api_test.go index f12ea8e2be..b639b87eab 100644 --- a/modules/compose/compose_api_test.go +++ b/modules/compose/compose_api_test.go @@ -12,6 +12,7 @@ import ( "github.com/docker/docker/api/types/volume" "github.com/google/uuid" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" "github.com/testcontainers/testcontainers-go" "github.com/testcontainers/testcontainers-go/wait" @@ -27,25 +28,25 @@ const ( func TestDockerComposeAPI(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) t.Cleanup(cancel) - assert.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") + require.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") } func TestDockerComposeAPIStrategyForInvalidService(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -56,22 +57,22 @@ func TestDockerComposeAPIStrategyForInvalidService(t *testing.T) { WaitForService("mysql-1", wait.NewLogStrategy("started").WithStartupTimeout(10*time.Second).WithOccurrence(1)). Up(ctx, Wait(true)) - assert.Error(t, err, "Expected error to be thrown because service with wait strategy is not running") - assert.Equal(t, err.Error(), "no container found for service name mysql-1") + require.Error(t, err, "Expected error to be thrown because service with wait strategy is not running") + require.Equal(t, "no container found for service name mysql-1", err.Error()) serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIWithWaitLogStrategy(t *testing.T) { path := filepath.Join(testdataPackage, complexCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -81,11 +82,11 @@ func TestDockerComposeAPIWithWaitLogStrategy(t *testing.T) { WaitForService("mysql", wait.NewLogStrategy("started").WithStartupTimeout(10*time.Second).WithOccurrence(1)). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 2, len(serviceNames)) + assert.Len(t, serviceNames, 2) assert.Contains(t, serviceNames, "nginx") assert.Contains(t, serviceNames, "mysql") } @@ -93,10 +94,10 @@ func TestDockerComposeAPIWithWaitLogStrategy(t *testing.T) { func TestDockerComposeAPIWithRunServices(t *testing.T) { path := filepath.Join(testdataPackage, complexCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -106,14 +107,14 @@ func TestDockerComposeAPIWithRunServices(t *testing.T) { WaitForService("nginx", wait.NewHTTPStrategy("/").WithPort("80/tcp").WithStartupTimeout(10*time.Second)). Up(ctx, Wait(true), RunServices("nginx")) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() _, err = compose.ServiceContainer(context.Background(), "mysql") - assert.Error(t, err, "Make sure there is no mysql container") + require.Error(t, err, "Make sure there is no mysql container") - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } @@ -122,34 +123,34 @@ func TestDockerComposeAPIWithStopServices(t *testing.T) { compose, err := NewDockerComposeWith( WithStackFiles(path), WithLogger(testcontainers.TestLogger(t))) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) t.Cleanup(cancel) - assert.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") + require.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 2, len(serviceNames)) + assert.Len(t, serviceNames, 2) assert.Contains(t, serviceNames, "nginx") assert.Contains(t, serviceNames, "mysql") // close mysql container in purpose mysqlContainer, err := compose.ServiceContainer(context.Background(), "mysql") - assert.NoError(t, err, "Get mysql container") + require.NoError(t, err, "Get mysql container") stopTimeout := 10 * time.Second err = mysqlContainer.Stop(ctx, &stopTimeout) - assert.NoError(t, err, "Stop mysql container") + require.NoError(t, err, "Stop mysql container") // check container status state, err := mysqlContainer.State(ctx) - assert.NoError(t, err) + require.NoError(t, err) assert.False(t, state.Running) assert.Equal(t, "exited", state.Status) } @@ -157,10 +158,10 @@ func TestDockerComposeAPIWithStopServices(t *testing.T) { func TestDockerComposeAPIWithWaitForService(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -173,21 +174,21 @@ func TestDockerComposeAPIWithWaitForService(t *testing.T) { WaitForService("nginx", wait.NewHTTPStrategy("/").WithPort("80/tcp").WithStartupTimeout(10*time.Second)). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIWithWaitHTTPStrategy(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -200,21 +201,21 @@ func TestDockerComposeAPIWithWaitHTTPStrategy(t *testing.T) { WaitForService("nginx", wait.NewHTTPStrategy("/").WithPort("80/tcp").WithStartupTimeout(10*time.Second)). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIWithContainerName(t *testing.T) { path := filepath.Join(testdataPackage, "docker-compose-container-name.yml") compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -227,21 +228,21 @@ func TestDockerComposeAPIWithContainerName(t *testing.T) { WaitForService("nginx", wait.NewHTTPStrategy("/").WithPort("80/tcp").WithStartupTimeout(10*time.Second)). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIWithWaitStrategy_NoExposedPorts(t *testing.T) { path := filepath.Join(testdataPackage, "docker-compose-no-exposed-ports.yml") compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -251,21 +252,21 @@ func TestDockerComposeAPIWithWaitStrategy_NoExposedPorts(t *testing.T) { WaitForService("nginx", wait.ForLog("Configuration complete; ready for start up")). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIWithMultipleWaitStrategies(t *testing.T) { path := filepath.Join(testdataPackage, complexCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -276,11 +277,11 @@ func TestDockerComposeAPIWithMultipleWaitStrategies(t *testing.T) { WaitForService("nginx", wait.NewHTTPStrategy("/").WithPort("80/tcp").WithStartupTimeout(10*time.Second)). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 2, len(serviceNames)) + assert.Len(t, serviceNames, 2) assert.Contains(t, serviceNames, "nginx") assert.Contains(t, serviceNames, "mysql") } @@ -288,10 +289,10 @@ func TestDockerComposeAPIWithMultipleWaitStrategies(t *testing.T) { func TestDockerComposeAPIWithFailedStrategy(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -306,31 +307,31 @@ func TestDockerComposeAPIWithFailedStrategy(t *testing.T) { // Verify that an error is thrown and not nil // A specific error message matcher is not asserted since the docker library can change the return message, breaking this test - assert.Error(t, err, "Expected error to be thrown because of a wrong suplied wait strategy") + require.Error(t, err, "Expected error to be thrown because of a wrong suplied wait strategy") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") } func TestDockerComposeAPIComplex(t *testing.T) { path := filepath.Join(testdataPackage, complexCompose) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) t.Cleanup(cancel) - assert.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") + require.NoError(t, compose.Up(ctx, Wait(true)), "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 2, len(serviceNames)) + assert.Len(t, serviceNames, 2) assert.Contains(t, serviceNames, "nginx") assert.Contains(t, serviceNames, "mysql") } @@ -341,10 +342,10 @@ func TestDockerComposeAPIWithEnvironment(t *testing.T) { path := filepath.Join(testdataPackage, simpleCompose) compose, err := NewDockerComposeWith(WithStackFiles(path), identifier) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -355,12 +356,11 @@ func TestDockerComposeAPIWithEnvironment(t *testing.T) { "bar": "BAR", }). Up(ctx, Wait(true)) - - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 1, len(serviceNames)) + assert.Len(t, serviceNames, 1) assert.Contains(t, serviceNames, "nginx") present := map[string]string{ @@ -380,10 +380,10 @@ func TestDockerComposeAPIWithMultipleComposeFiles(t *testing.T) { identifier := testNameHash(t.Name()) compose, err := NewDockerComposeWith(composeFiles, identifier) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -395,11 +395,11 @@ func TestDockerComposeAPIWithMultipleComposeFiles(t *testing.T) { "foo": "FOO", }). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") serviceNames := compose.Services() - assert.Equal(t, 3, len(serviceNames)) + assert.Len(t, serviceNames, 3) assert.Contains(t, serviceNames, "nginx") assert.Contains(t, serviceNames, "mysql") assert.Contains(t, serviceNames, "postgres") @@ -415,17 +415,17 @@ func TestDockerComposeAPIWithMultipleComposeFiles(t *testing.T) { func TestDockerComposeAPIWithVolume(t *testing.T) { path := filepath.Join(testdataPackage, composeWithVolume) compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) t.Cleanup(cancel) err = compose.Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") } func TestDockerComposeAPIVolumesDeletedOnDown(t *testing.T) { @@ -433,24 +433,24 @@ func TestDockerComposeAPIVolumesDeletedOnDown(t *testing.T) { identifier := uuid.New().String() stackFiles := WithStackFiles(path) compose, err := NewDockerComposeWith(stackFiles, StackIdentifier(identifier)) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") ctx, cancel := context.WithCancel(context.Background()) t.Cleanup(cancel) err = compose.Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") err = compose.Down(context.Background(), RemoveOrphans(true), RemoveVolumes(true), RemoveImagesLocal) - assert.NoError(t, err, "compose.Down()") + require.NoError(t, err, "compose.Down()") volumeListFilters := filters.NewArgs() // the "mydata" identifier comes from the "testdata/docker-compose-volume.yml" file volumeListFilters.Add("name", fmt.Sprintf("%s_mydata", identifier)) volumeList, err := compose.dockerClient.VolumeList(ctx, volume.ListOptions{Filters: volumeListFilters}) - assert.NoError(t, err, "compose.dockerClient.VolumeList()") + require.NoError(t, err, "compose.dockerClient.VolumeList()") - assert.Equal(t, 0, len(volumeList.Volumes), "Volumes are not cleaned up") + assert.Empty(t, volumeList.Volumes, "Volumes are not cleaned up") } func TestDockerComposeAPIWithBuild(t *testing.T) { @@ -458,10 +458,10 @@ func TestDockerComposeAPIWithBuild(t *testing.T) { path := filepath.Join(testdataPackage, "docker-compose-build.yml") compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -471,16 +471,16 @@ func TestDockerComposeAPIWithBuild(t *testing.T) { WaitForService("echo", wait.ForHTTP("/env").WithPort("8080/tcp")). Up(ctx, Wait(true)) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") } func TestDockerComposeApiWithWaitForShortLifespanService(t *testing.T) { path := filepath.Join(testdataPackage, "docker-compose-short-lifespan.yml") compose, err := NewDockerCompose(path) - assert.NoError(t, err, "NewDockerCompose()") + require.NoError(t, err, "NewDockerCompose()") t.Cleanup(func() { - assert.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") + require.NoError(t, compose.Down(context.Background(), RemoveOrphans(true), RemoveImagesLocal), "compose.Down()") }) ctx, cancel := context.WithCancel(context.Background()) @@ -492,11 +492,11 @@ func TestDockerComposeApiWithWaitForShortLifespanService(t *testing.T) { WaitForService("falafel", wait.ForExit().WithExitTimeout(10*time.Second)). Up(ctx) - assert.NoError(t, err, "compose.Up()") + require.NoError(t, err, "compose.Up()") services := compose.Services() - assert.Equal(t, 2, len(services)) + assert.Len(t, services, 2) assert.Contains(t, services, "falafel") assert.Contains(t, services, "tzatziki") } diff --git a/modules/compose/compose_local.go b/modules/compose/compose_local.go index 80bdc41ab9..c008e2ec9d 100644 --- a/modules/compose/compose_local.go +++ b/modules/compose/compose_local.go @@ -12,7 +12,7 @@ import ( "strings" "sync" - "github.com/docker/docker/api/types" + "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/filters" "gopkg.in/yaml.v3" @@ -135,7 +135,7 @@ func (dc *LocalDockerCompose) applyStrategyToRunningContainer() error { filters.Arg("name", containerName), filters.Arg("name", composeV2ContainerName), filters.Arg("name", k.service)) - containerListOptions := types.ContainerListOptions{Filters: f, All: true} + containerListOptions := container.ListOptions{Filters: f, All: true} containers, err := cli.ContainerList(context.Background(), containerListOptions) if err != nil { return fmt.Errorf("error %w occurred while filtering the service %s: %d by name and published port", err, k.service, k.publishedPort) @@ -211,8 +211,8 @@ func (dc *LocalDockerCompose) determineVersion() error { } components := bytes.Split(execErr.StdoutOutput, []byte(".")) - if componentsLen := len(components); componentsLen != 3 { - return fmt.Errorf("expected 3 version components in %s", execErr.StdoutOutput) + if componentsLen := len(components); componentsLen < 3 { + return fmt.Errorf("expected +3 version components in %s", execErr.StdoutOutput) } majorVersion, err := strconv.ParseInt(string(components[0]), 10, 8) diff --git a/modules/compose/compose_test.go b/modules/compose/compose_test.go index 10d23f1059..bffec7bd94 100644 --- a/modules/compose/compose_test.go +++ b/modules/compose/compose_test.go @@ -9,11 +9,12 @@ import ( "testing" "time" - "github.com/docker/docker/api/types" + "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/api/types/volume" "github.com/google/uuid" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" "github.com/testcontainers/testcontainers-go" "github.com/testcontainers/testcontainers-go/wait" @@ -136,9 +137,9 @@ func TestDockerComposeStrategyForInvalidService(t *testing.T) { // Appending with _1 as given in the Java Test-Containers Example WithExposedService(compose.Format("mysql", "1"), 13306, wait.NewLogStrategy("started").WithStartupTimeout(10*time.Second).WithOccurrence(1)). Invoke() - assert.NotEqual(t, err.Error, nil, "Expected error to be thrown because service with wait strategy is not running") + require.Error(t, err.Error, "Expected error to be thrown because service with wait strategy is not running") - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -161,7 +162,7 @@ func TestDockerComposeWithWaitLogStrategy(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 2, len(compose.Services)) + assert.Len(t, compose.Services, 2) assert.Contains(t, compose.Services, "nginx") assert.Contains(t, compose.Services, "mysql") } @@ -187,7 +188,7 @@ func TestDockerComposeWithWaitForService(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -211,7 +212,7 @@ func TestDockerComposeWithWaitForShortLifespanService(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 2, len(compose.Services)) + assert.Len(t, compose.Services, 2) assert.Contains(t, compose.Services, "falafel") assert.Contains(t, compose.Services, "tzatziki") } @@ -237,7 +238,7 @@ func TestDockerComposeWithWaitHTTPStrategy(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -262,7 +263,7 @@ func TestDockerComposeWithContainerName(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -284,7 +285,7 @@ func TestDockerComposeWithWaitStrategy_NoExposedPorts(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -307,7 +308,7 @@ func TestDockerComposeWithMultipleWaitStrategies(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 2, len(compose.Services)) + assert.Len(t, compose.Services, 2) assert.Contains(t, compose.Services, "nginx") assert.Contains(t, compose.Services, "mysql") } @@ -333,9 +334,9 @@ func TestDockerComposeWithFailedStrategy(t *testing.T) { Invoke() // Verify that an error is thrown and not nil // A specific error message matcher is not asserted since the docker library can change the return message, breaking this test - assert.NotEqual(t, err.Error, nil, "Expected error to be thrown because of a wrong suplied wait strategy") + require.Error(t, err.Error, "Expected error to be thrown because of a wrong suplied wait strategy") - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") } @@ -356,7 +357,7 @@ func TestLocalDockerComposeComplex(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 2, len(compose.Services)) + assert.Len(t, compose.Services, 2) assert.Contains(t, compose.Services, "nginx") assert.Contains(t, compose.Services, "mysql") } @@ -381,7 +382,7 @@ func TestLocalDockerComposeWithEnvironment(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 1, len(compose.Services)) + assert.Len(t, compose.Services, 1) assert.Contains(t, compose.Services, "nginx") present := map[string]string{ @@ -416,7 +417,7 @@ func TestLocalDockerComposeWithMultipleComposeFiles(t *testing.T) { Invoke() checkIfError(t, err) - assert.Equal(t, 3, len(compose.Services)) + assert.Len(t, compose.Services, 3) assert.Contains(t, compose.Services, "nginx") assert.Contains(t, compose.Services, "mysql") assert.Contains(t, compose.Services, "postgres") @@ -479,7 +480,7 @@ func assertContainerEnvironmentVariables( tb.Fatalf("Failed to get provider: %v", err) } - containers, err := containerClient.ContainerList(context.Background(), types.ContainerListOptions{}) + containers, err := containerClient.ContainerList(context.Background(), container.ListOptions{}) if err != nil { tb.Fatalf("Failed to list containers: %v", err) } else if len(containers) == 0 { diff --git a/modules/compose/go.mod b/modules/compose/go.mod index 8f16883411..477796b31b 100644 --- a/modules/compose/go.mod +++ b/modules/compose/go.mod @@ -7,14 +7,14 @@ toolchain go1.21.3 replace github.com/testcontainers/testcontainers-go => ../.. require ( - github.com/compose-spec/compose-go v1.20.2 - github.com/docker/cli v24.0.7+incompatible - github.com/docker/compose/v2 v2.23.3 - github.com/docker/docker v24.0.7+incompatible + github.com/compose-spec/compose-go/v2 v2.0.0-rc.1 + github.com/docker/cli v25.0.0-rc.3+incompatible + github.com/docker/compose/v2 v2.24.1 + github.com/docker/docker v25.0.0-rc.3+incompatible github.com/google/uuid v1.5.0 github.com/stretchr/testify v1.8.4 github.com/testcontainers/testcontainers-go v0.27.0 - golang.org/x/sync v0.5.0 + golang.org/x/sync v0.6.0 gopkg.in/yaml.v3 v3.0.1 ) @@ -43,22 +43,22 @@ require ( github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/containerd/console v1.0.3 // indirect - github.com/containerd/containerd v1.7.11 // indirect + github.com/containerd/containerd v1.7.12 // indirect github.com/containerd/continuity v0.4.2 // indirect github.com/containerd/log v0.1.0 // indirect github.com/containerd/typeurl/v2 v2.1.1 // indirect github.com/cpuguy83/dockercfg v0.3.1 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/distribution/reference v0.5.0 // indirect - github.com/docker/buildx v0.12.0 // indirect - github.com/docker/distribution v2.8.2+incompatible // indirect - github.com/docker/docker-credential-helpers v0.7.0 // indirect + github.com/docker/buildx v0.12.0-rc2.0.20231219140829-617f538cb315 // indirect + github.com/docker/distribution v2.8.3+incompatible // indirect + github.com/docker/docker-credential-helpers v0.8.0 // indirect github.com/docker/go v1.5.1-1.0.20160303222718-d30aec9fd63c // indirect github.com/docker/go-connections v0.5.0 // indirect github.com/docker/go-metrics v0.0.1 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/emicklei/go-restful/v3 v3.10.1 // indirect - github.com/felixge/httpsnoop v1.0.3 // indirect + github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsevents v0.1.1 // indirect github.com/fvbommel/sortorder v1.0.2 // indirect github.com/go-logr/logr v1.2.4 // indirect @@ -70,13 +70,12 @@ require ( github.com/gofrs/flock v0.8.1 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/mock v1.6.0 // indirect github.com/golang/protobuf v1.5.3 // indirect github.com/google/gnostic v0.5.7-v3refs // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 // indirect - github.com/gorilla/mux v1.8.0 // indirect + github.com/gorilla/mux v1.8.1 // indirect github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect @@ -90,19 +89,21 @@ require ( github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect - github.com/klauspost/compress v1.16.5 // indirect + github.com/klauspost/compress v1.17.4 // indirect github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/mailru/easyjson v0.7.6 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.17 // indirect - github.com/mattn/go-runewidth v0.0.14 // indirect + github.com/mattn/go-runewidth v0.0.15 // indirect github.com/mattn/go-shellwords v1.0.12 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b // indirect github.com/miekg/pkcs11 v1.1.1 // indirect + github.com/mitchellh/copystructure v1.2.0 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect - github.com/moby/buildkit v0.13.0-beta1.0.20231023114302-d5c1d785b042 // indirect + github.com/mitchellh/reflectwalk v1.0.2 // indirect + github.com/moby/buildkit v0.13.0-beta1.0.20231219135447-957cb50df991 // indirect github.com/moby/locker v1.0.1 // indirect github.com/moby/patternmatcher v0.6.0 // indirect github.com/moby/spdystream v0.2.0 // indirect @@ -110,6 +111,7 @@ require ( github.com/moby/sys/sequential v0.5.0 // indirect github.com/moby/sys/signal v0.7.0 // indirect github.com/moby/sys/symlink v0.2.0 // indirect + github.com/moby/sys/user v0.1.0 // indirect github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect @@ -117,7 +119,6 @@ require ( github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0-rc5 // indirect - github.com/opencontainers/runc v1.1.9 // indirect github.com/pelletier/go-toml v1.9.5 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect @@ -139,7 +140,7 @@ require ( github.com/tilt-dev/fsnotify v1.4.8-0.20220602155310-fff9c274a375 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect - github.com/tonistiigi/fsutil v0.0.0-20230629203738-36ef4d8c0dbb // indirect + github.com/tonistiigi/fsutil v0.0.0-20230825212630-f09800878302 // indirect github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea // indirect github.com/tonistiigi/vt100 v0.0.0-20230623042737-f9a4f7ef6531 // indirect github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb // indirect @@ -150,13 +151,19 @@ require ( go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.45.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 // indirect go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlpmetric v0.42.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v0.42.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp v0.42.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.19.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.19.0 // indirect + go.opentelemetry.io/otel/exporters/prometheus v0.42.0 // indirect go.opentelemetry.io/otel/metric v1.19.0 // indirect go.opentelemetry.io/otel/sdk v1.19.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.19.0 // indirect go.opentelemetry.io/otel/trace v1.19.0 // indirect go.opentelemetry.io/proto/otlp v1.0.0 // indirect + go.uber.org/mock v0.4.0 // indirect golang.org/x/crypto v0.17.0 // indirect golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 // indirect golang.org/x/mod v0.11.0 // indirect @@ -177,6 +184,7 @@ require ( gopkg.in/yaml.v2 v2.4.0 // indirect k8s.io/api v0.26.7 // indirect k8s.io/apimachinery v0.26.7 // indirect + k8s.io/apiserver v0.26.7 // indirect k8s.io/client-go v0.26.7 // indirect k8s.io/klog/v2 v2.90.1 // indirect k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 // indirect @@ -184,4 +192,5 @@ require ( sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect sigs.k8s.io/yaml v1.3.0 // indirect + tags.cncf.io/container-device-interface v0.6.2 // indirect ) diff --git a/modules/compose/go.sum b/modules/compose/go.sum index 03c2b260e9..14ddac8387 100644 --- a/modules/compose/go.sum +++ b/modules/compose/go.sum @@ -86,22 +86,22 @@ github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4 h1:/inchEIKaYC1Akx+H+g github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/codahale/rfc6979 v0.0.0-20141003034818-6a90f24967eb h1:EDmT6Q9Zs+SbUoc7Ik9EfrFqcylYqgPZ9ANSbTAntnE= github.com/codahale/rfc6979 v0.0.0-20141003034818-6a90f24967eb/go.mod h1:ZjrT6AXHbDs86ZSdt/osfBi5qfexBrKUdONk989Wnk4= -github.com/compose-spec/compose-go v1.20.2 h1:u/yfZHn4EaHGdidrZycWpxXgFffjYULlTbRfJ51ykjQ= -github.com/compose-spec/compose-go v1.20.2/go.mod h1:+MdqXV4RA7wdFsahh/Kb8U0pAJqkg7mr4PM9tFKU8RM= +github.com/compose-spec/compose-go/v2 v2.0.0-rc.1 h1:0nnSpdYg29uaQOU/YJ1YSgYgwkQr/XNZ0QAFtEPTtIA= +github.com/compose-spec/compose-go/v2 v2.0.0-rc.1/go.mod h1:IVsvFyGVhw4FASzUtlWNVaAOhYmakXAFY9IlZ7LAuD8= github.com/containerd/cgroups v1.1.0 h1:v8rEWFl6EoqHB+swVNjVoCJE8o3jX7e8nqBGPLaDFBM= github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHqJDGwsa1mIw= github.com/containerd/console v1.0.3 h1:lIr7SlA5PxZyMV30bDW0MGbiOPXwc63yRuCP0ARubLw= github.com/containerd/console v1.0.3/go.mod h1:7LqA/THxQ86k76b8c/EMSiaJ3h1eZkMkXar0TQ1gf3U= -github.com/containerd/containerd v1.7.11 h1:lfGKw3eU35sjV0aG2eYZTiwFEY1pCzxdzicHP3SZILw= -github.com/containerd/containerd v1.7.11/go.mod h1:5UluHxHTX2rdvYuZ5OJTC5m/KJNs0Zs9wVoJm9zf5ZE= +github.com/containerd/containerd v1.7.12 h1:+KQsnv4VnzyxWcfO9mlxxELaoztsDEjOuCMPAuPqgU0= +github.com/containerd/containerd v1.7.12/go.mod h1:/5OMpE1p0ylxtEUGY8kuCYkDRzJm9NO1TFMWjUpdevk= github.com/containerd/continuity v0.4.2 h1:v3y/4Yz5jwnvqPKJJ+7Wf93fyWoCB3F5EclWG023MDM= github.com/containerd/continuity v0.4.2/go.mod h1:F6PTNCKepoxEaXLQp3wDAjygEnImnZ/7o4JzpodfroQ= github.com/containerd/fifo v1.1.0 h1:4I2mbh5stb1u6ycIABlBw9zgtlK8viPI9QkQNRQEEmY= github.com/containerd/fifo v1.1.0/go.mod h1:bmC4NWMbXlt2EZ0Hc7Fx7QzTFxgPID13eH0Qu+MAb2o= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= -github.com/containerd/nydus-snapshotter v0.8.2 h1:7SOrMU2YmLzfbsr5J7liMZJlNi5WT6vtIOxLGv+iz7E= -github.com/containerd/nydus-snapshotter v0.8.2/go.mod h1:UJILTN5LVBRY+dt8BGJbp72Xy729hUZsOugObEI3/O8= +github.com/containerd/nydus-snapshotter v0.13.1 h1:5XNkCZ9ivLXCcyx3Jbbfh/fntkcls69uBg0x9VE8zlk= +github.com/containerd/nydus-snapshotter v0.13.1/go.mod h1:XWAz9ytsjBuKPVXDKP3xoMlcSKNsGnjXlEup6DuzUIo= github.com/containerd/stargz-snapshotter v0.14.3 h1:OTUVZoPSPs8mGgmQUE1dqw3WX/3nrsmsurW7UPLWl1U= github.com/containerd/stargz-snapshotter/estargz v0.14.3 h1:OqlDCK3ZVUO6C3B/5FSkDwbkEETK84kQgEeFwDC+62k= github.com/containerd/stargz-snapshotter/estargz v0.14.3/go.mod h1:KY//uOCIkSuNAHhJogcZtrNHdKrA99/FCCRjE3HD36o= @@ -122,19 +122,19 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/denisenkom/go-mssqldb v0.0.0-20191128021309-1d7a30a10f73/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= github.com/distribution/reference v0.5.0 h1:/FUIFXtfc/x2gpa5/VGfiGLuOIdYa1t65IKK2OFGvA0= github.com/distribution/reference v0.5.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= -github.com/docker/buildx v0.12.0 h1:pI4jr4SeH9oHa0SmMvH/lz+Rdqkg+dRa9H/1VXbYgws= -github.com/docker/buildx v0.12.0/go.mod h1:SBLnQH9q+77aVvpvS5LLIly9+nHVlwscl5GEegGMD5g= -github.com/docker/cli v24.0.7+incompatible h1:wa/nIwYFW7BVTGa7SWPVyyXU9lgORqUb1xfI36MSkFg= -github.com/docker/cli v24.0.7+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= -github.com/docker/compose/v2 v2.23.3 h1:2p2biZqpUvPzC8J7nDl+ankVQNCCAk2IZJ4eg1S+6BE= -github.com/docker/compose/v2 v2.23.3/go.mod h1:lUweVMN13YR0a9M7qdKulTSMS1kYdAysYNJlFEnDMCw= +github.com/docker/buildx v0.12.0-rc2.0.20231219140829-617f538cb315 h1:UZxx9xBADdf/9UmSdEUi+pdJoPKpgcf9QUAY5gEIYmY= +github.com/docker/buildx v0.12.0-rc2.0.20231219140829-617f538cb315/go.mod h1:X8ZHhuW6ncwtoJ36TlU+gyaROTcBkTE01VHYmTStQCE= +github.com/docker/cli v25.0.0-rc.3+incompatible h1:pk9OUWCVWtxZC5n9n4heCBSJq2IT6nixGUFDznbMtwo= +github.com/docker/cli v25.0.0-rc.3+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/compose/v2 v2.24.1 h1:Mk14AOkxetMKrWb1bOnx7bEfS+v/moaCZnU69QqUw6A= +github.com/docker/compose/v2 v2.24.1/go.mod h1:rrqu0bPBN/HD2wRSNwVN+V9SDfhVQnKxF1DP9B9WOdI= github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= -github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= -github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker-credential-helpers v0.7.0 h1:xtCHsjxogADNZcdv1pKUHXryefjlVRqWqIhk/uXJp0A= -github.com/docker/docker-credential-helpers v0.7.0/go.mod h1:rETQfLdHNT3foU5kuNkFR1R1V12OJRRO5lzt2D1b5X0= +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 v25.0.0-rc.3+incompatible h1:f2YaukI/rOEueLwmDGAVcES5E8Y+BT/e7pQWLu/WZSk= +github.com/docker/docker v25.0.0-rc.3+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker-credential-helpers v0.8.0 h1:YQFtbBQb4VrpoPxhFuzEBPQ9E16qz5SpHLS+uswaCp8= +github.com/docker/docker-credential-helpers v0.8.0/go.mod h1:UGFXcuoQ5TxPiB54nHOZ32AWRqQdECoh/Mg0AlEYb40= github.com/docker/go v1.5.1-1.0.20160303222718-d30aec9fd63c h1:lzqkGL9b3znc+ZUgi7FlLnqjQhcXxkNM/quxIjBVMD0= github.com/docker/go v1.5.1-1.0.20160303222718-d30aec9fd63c/go.mod h1:CADgU4DSXK5QUlFslkQu2yW2TKzFZcXq/leZfM0UH5Q= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= @@ -162,8 +162,8 @@ github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7 github.com/envoyproxy/protoc-gen-validate v1.0.2 h1:QkIBuU5k+x7/QXPvPPnWXWlCdaBFApVqftFV6k087DA= github.com/envoyproxy/protoc-gen-validate v1.0.2/go.mod h1:GpiZQP3dDbg4JouG/NNS7QWXpgx6x8QiMKdmN72jogE= github.com/erikstmartin/go-testdb v0.0.0-20160219214506-8d10e4a1bae5/go.mod h1:a2zkGnVExMxdzMo3M0Hi/3sEU+cWnZpSni0O6/Yb/P0= -github.com/felixge/httpsnoop v1.0.3 h1:s/nj+GCswXYzN5v2DpNMuMQYe+0DDwt5WVCU6CWBdXk= -github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= +github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fsnotify/fsevents v0.1.1 h1:/125uxJvvoSDDBPen6yUZbil8J9ydKZnnl3TWWmvnkw= github.com/fsnotify/fsevents v0.1.1/go.mod h1:+d+hS27T6k5J8CRaPLKFgwKYcpS7GwW3Ule9+SC2ZRc= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= @@ -207,8 +207,6 @@ github.com/golang/glog v1.1.2/go.mod h1:zR+okUeTbrL6EL3xHUDxZuEtGv04p5shwip1+mL/ github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -246,8 +244,8 @@ github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3 github.com/google/uuid v1.5.0 h1:1p67kYwdtXjb0gL0BPiP1Av9wiZPo5A8z2cWkTZ+eyU= github.com/google/uuid v1.5.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/gorilla/mux v1.7.0/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= +github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= +github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= @@ -295,8 +293,8 @@ github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNU github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.16.5 h1:IFV2oUNUzZaz+XyusxpLzpzS8Pt5rh0Z16For/djlyI= -github.com/klauspost/compress v1.16.5/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/compress v1.17.4 h1:Ej5ixsIri7BrIjBkRZLTo6ghwrEtHFk7ijlczPW4fZ4= +github.com/klauspost/compress v1.17.4/go.mod h1:/dCuZOvVtNoHsyb+cuJD3itjs3NbnF6KH9zAO4BDxPM= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= @@ -325,8 +323,8 @@ github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hd github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-isatty v0.0.17 h1:BTarxUcIeDqL27Mc+vyvdWYSL28zpIhv3RoTdsLMPng= github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= -github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/mattn/go-runewidth v0.0.15 h1:UNAjwbU9l54TA3KzvqLGxwWjHmMgBUVhBiTjelZgg3U= +github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/mattn/go-shellwords v1.0.12 h1:M2zGm7EW6UQJvDeQxo4T51eKPurbeFbe8WtebGE2xrk= github.com/mattn/go-shellwords v1.0.12/go.mod h1:EZzvwXDESEeg03EKmM+RmDnNOPKG4lLtQsUlTZDWQ8Y= github.com/mattn/go-sqlite3 v1.6.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= @@ -338,11 +336,15 @@ github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyex github.com/miekg/pkcs11 v1.0.2/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs= github.com/miekg/pkcs11 v1.1.1 h1:Ugu9pdy6vAYku5DEpVWVFPYnzV+bxB+iRdbuFSu7TvU= github.com/miekg/pkcs11 v1.1.1/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs= +github.com/mitchellh/copystructure v1.2.0 h1:vpKXTN4ewci03Vljg/q9QvCGUDttBOGBIa15WveJJGw= +github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= github.com/mitchellh/mapstructure v0.0.0-20150613213606-2caf8efc9366/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= 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.13.0-beta1.0.20231023114302-d5c1d785b042 h1:1J+fRIucIeyl1gvSYOlTcN0gmsZ8SMlLdkwB01PEn94= -github.com/moby/buildkit v0.13.0-beta1.0.20231023114302-d5c1d785b042/go.mod h1:3sbzGMUHhpx+6++efVlHhvcarzusX1+QbGTR/S4y9gI= +github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= +github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +github.com/moby/buildkit v0.13.0-beta1.0.20231219135447-957cb50df991 h1:r80LLQ91uOLxU1ElAvrB1o8oBsph51lPzVnr7t2b200= +github.com/moby/buildkit v0.13.0-beta1.0.20231219135447-957cb50df991/go.mod h1:6MddWPSL5jxy+W8eMMHWDOfZzzRRKWXPZqajw72YHBc= github.com/moby/locker v1.0.1 h1:fOXqR41zeveg4fFODix+1Ch4mj/gT0NE1XJbp/epuBg= github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= @@ -357,6 +359,8 @@ github.com/moby/sys/signal v0.7.0 h1:25RW3d5TnQEoKvRbEKUGay6DCQ46IxAVTT9CUMgmsSI github.com/moby/sys/signal v0.7.0/go.mod h1:GQ6ObYZfqacOwTtlXvcmh9A26dVRul/hbOZn88Kg8Tg= github.com/moby/sys/symlink v0.2.0 h1:tk1rOM+Ljp0nFmfOIBtlV3rTDlWOwFRhjEeAhZB0nZc= github.com/moby/sys/symlink v0.2.0/go.mod h1:7uZVF2dqJjG/NsClqul95CqKOBRQyYSNnJ6BMgR/gFs= +github.com/moby/sys/user v0.1.0 h1:WmZ93f5Ux6het5iituh9x2zAG7NFY9Aqi49jjE1PaQg= +github.com/moby/sys/user v0.1.0/go.mod h1:fKJhFOnsCN6xZ5gSfbM6zaHGgDJMrqt9/reuj4T7MmU= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -387,10 +391,8 @@ github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3I github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= github.com/opencontainers/image-spec v1.1.0-rc5 h1:Ygwkfw9bpDvs+c9E34SdgGOj41dX/cbdlwvlWt0pnFI= github.com/opencontainers/image-spec v1.1.0-rc5/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= -github.com/opencontainers/runc v1.1.9 h1:XR0VIHTGce5eWPkaPesqTBrhW2yAcaraWfsEalNwQLM= -github.com/opencontainers/runc v1.1.9/go.mod h1:CbUumNnWCuTGFukNXahoo/RFBZvDAgRh/smNYNOhA50= -github.com/opencontainers/runtime-spec v1.1.0-rc.2 h1:ucBtEms2tamYYW/SvGpvq9yUN0NEVL6oyLEwDcTSrk8= -github.com/opencontainers/runtime-spec v1.1.0-rc.2/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= +github.com/opencontainers/runtime-spec v1.1.0 h1:HHUyrt9mwHUjtasSbXSMvs4cyFxh+Bll4AjJ9odEGpg= +github.com/opencontainers/runtime-spec v1.1.0/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= github.com/opencontainers/selinux v1.11.0 h1:+5Zbo97w3Lbmb3PeqQtpmTkMwsW5nRI3YaLpt7tQ7oU= github.com/opencontainers/selinux v1.11.0/go.mod h1:E5dMC3VPuVvVHDYmi78qvhJp8+M586T4DlDRYpFkyec= github.com/opentracing/opentracing-go v1.1.0 h1:pWlfV3Bxv7k65HYwkikxat0+s3pV4bsqf19k25Ur8rU= @@ -489,14 +491,14 @@ github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFA github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= -github.com/tonistiigi/fsutil v0.0.0-20230629203738-36ef4d8c0dbb h1:uUe8rNyVXM8moActoBol6Xf6xX2GMr7SosR2EywMvGg= -github.com/tonistiigi/fsutil v0.0.0-20230629203738-36ef4d8c0dbb/go.mod h1:SxX/oNQ/ag6Vaoli547ipFK9J7BZn5JqJG0JE8lf8bA= +github.com/tonistiigi/fsutil v0.0.0-20230825212630-f09800878302 h1:ZT8ibgassurSISJ1Pj26NsM3vY2jxFZn63Nd/TpHmRw= +github.com/tonistiigi/fsutil v0.0.0-20230825212630-f09800878302/go.mod h1:9kMVqMyQ/Sx2df5LtnGG+nbrmiZzCS7V6gjW3oGHsvI= github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea h1:SXhTLE6pb6eld/v/cCndK0AMpt1wiVFb/YYmqB3/QG0= github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea/go.mod h1:WPnis/6cRcDZSUvVmezrxJPkiO87ThFYsoUiMwWNDJk= github.com/tonistiigi/vt100 v0.0.0-20230623042737-f9a4f7ef6531 h1:Y/M5lygoNPKwVNLMPXgVfsRT40CSFKXCxuU8LoHySjs= github.com/tonistiigi/vt100 v0.0.0-20230623042737-f9a4f7ef6531/go.mod h1:ulncasL3N9uLrVann0m+CDlJKWsIAP34MPcOJF6VRvc= -github.com/vbatts/tar-split v0.11.2 h1:Via6XqJr0hceW4wff3QRzD5gAk/tatMw/4ZA7cTlIME= -github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI= +github.com/vbatts/tar-split v0.11.3 h1:hLFqsOLQ1SsppQNTMpkpPXClLDfC2A3Zgy9OUU+RVck= +github.com/vbatts/tar-split v0.11.3/go.mod h1:9QlHN18E+fEH7RdG+QAJJcuya3rqT7eXSTY7wGrAokY= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb h1:zGWFAtiMcyryUHoUjUJX0/lt1H2+i2Ka2n+D3DImSNo= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= @@ -506,7 +508,6 @@ github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17 github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= @@ -520,16 +521,26 @@ go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 h1:x8Z78aZ go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0/go.mod h1:62CPTSry9QZtOaSsE3tOzhx6LzDhHnXJ6xHeMNNiM6Q= go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric v0.42.0 h1:ZtfnDL+tUrs1F0Pzfwbg2d59Gru9NCH3bgSHBM6LDwU= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric v0.42.0/go.mod h1:hG4Fj/y8TR/tlEDREo8tWstl9fO9gcFkn4xrx0Io8xU= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v0.42.0 h1:NmnYCiR0qNufkldjVvyQfZTHSdzeHoZ41zggMsdMcLM= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v0.42.0/go.mod h1:UVAO61+umUsHLtYb8KXXRoHtxUkdOPkYidzW3gipRLQ= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp v0.42.0 h1:wNMDy/LVGLj2h3p6zg4d0gypKfWKSWI14E1C4smOgl8= +go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp v0.42.0/go.mod h1:YfbDdXAAkemWJK3H/DshvlrxqFB2rtW4rY6ky/3x/H0= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0 h1:Mne5On7VWdx7omSrSSZvM4Kw7cS7NQkOOmLcgscI51U= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0/go.mod h1:IPtUMKL4O3tH5y+iXVyAXqpAwMuzC1IrxVS81rummfE= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.19.0 h1:3d+S281UTjM+AbF31XSOYn1qXn3BgIdWl8HNEpx08Jk= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.19.0/go.mod h1:0+KuTDyKL4gjKCF75pHOX4wuzYDUZYfAQdSu43o+Z2I= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.19.0 h1:IeMeyr1aBvBiPVYihXIaeIZba6b8E1bYp7lbdxK8CQg= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.19.0/go.mod h1:oVdCUtjq9MK9BlS7TtucsQwUcXcymNiEDjgDD2jMtZU= +go.opentelemetry.io/otel/exporters/prometheus v0.42.0 h1:jwV9iQdvp38fxXi8ZC+lNpxjK16MRcZlpDYvbuO1FiA= +go.opentelemetry.io/otel/exporters/prometheus v0.42.0/go.mod h1:f3bYiqNqhoPxkvI2LrXqQVC546K7BuRDL/kKuxkujhA= go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= +go.opentelemetry.io/otel/sdk/metric v1.19.0 h1:EJoTO5qysMsYCa+w4UghwFV/ptQgqSL/8Ni+hx+8i1k= +go.opentelemetry.io/otel/sdk/metric v1.19.0/go.mod h1:XjG0jQyFJrv2PbMvwND7LwCEhsJzCzV5210euduKcKY= go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= go.opentelemetry.io/proto/otlp v1.0.0 h1:T0TX0tmXU8a3CbNXzEKGeU5mIVOdf0oykP+u2lIVU/I= @@ -537,6 +548,8 @@ go.opentelemetry.io/proto/otlp v1.0.0/go.mod h1:Sy6pihPLfYHkr3NkUbEhGHFhINUSI/v8 go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= +go.uber.org/mock v0.4.0 h1:VcM4ZOtdbR4f6VXfiOpwpVJDL6lCReaZ6mw31wqh7KU= +go.uber.org/mock v0.4.0/go.mod h1:a6FSlNadKUHUa9IP5Vyt1zh4fC7uAwxMutEAscFbkZc= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= @@ -557,7 +570,6 @@ golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvx golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.11.0 h1:bUO06HqtnRcc/7l71XBe4WcqTZ+3AH1J59zWDDwLKgU= golang.org/x/mod v0.11.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= @@ -574,7 +586,6 @@ golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= @@ -587,10 +598,9 @@ golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= -golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= +golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -607,9 +617,7 @@ golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201204225414-ed752295db88/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -645,7 +653,6 @@ golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.10.0 h1:tvDr/iQoUqNdohiYm0LmmKcBk+q86lb9EprIUFhHHGg= golang.org/x/tools v0.10.0/go.mod h1:UJwyiVBsOA2uwvK/e5OY3GTpDUJriEd+/YlqAwLPmyM= @@ -724,6 +731,8 @@ k8s.io/api v0.26.7 h1:Lf4iEBEJb5OFNmawtBfSZV/UNi9riSJ0t1qdhyZqI40= k8s.io/api v0.26.7/go.mod h1:Vk9bMadzA49UHPmHB//lX7VRCQSXGoVwfLd3Sc1SSXI= k8s.io/apimachinery v0.26.7 h1:590jSBwaSHCAFCqltaEogY/zybFlhGsnLteLpuF2wig= k8s.io/apimachinery v0.26.7/go.mod h1:qYzLkrQ9lhrZRh0jNKo2cfvf/R1/kQONnSiyB7NUJU0= +k8s.io/apiserver v0.26.7 h1:NX/zBZZn4R+Cq6shwyn8Pn8REd0yJJ16dbtv9WkEVEU= +k8s.io/apiserver v0.26.7/go.mod h1:r0wDRWHI7VL/KlQLTkJJBVGZ3KeNfv+VetlyRtr86xs= k8s.io/client-go v0.26.7 h1:hyU9aKHlwVOykgyxzGYkrDSLCc4+mimZVyUJjPyUn1E= k8s.io/client-go v0.26.7/go.mod h1:okYjy0jtq6sdeztALDvCh24tg4opOQS1XNvsJlERDAo= k8s.io/klog/v2 v2.90.1 h1:m4bYOKall2MmOiRaR1J+We67Do7vm9KiQVlT96lnHUw= @@ -738,3 +747,5 @@ sigs.k8s.io/structured-merge-diff/v4 v4.2.3 h1:PRbqxJClWWYMNV1dhaG4NsibJbArud9kF sigs.k8s.io/structured-merge-diff/v4 v4.2.3/go.mod h1:qjx8mGObPmV2aSZepjQjbmb2ihdVs8cGKBraizNC69E= sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= +tags.cncf.io/container-device-interface v0.6.2 h1:dThE6dtp/93ZDGhqaED2Pu374SOeUkBfuvkLuiTdwzg= +tags.cncf.io/container-device-interface v0.6.2/go.mod h1:Shusyhjs1A5Na/kqPVLL0KqnHQHuunol9LFeUNkuGVE= diff --git a/modules/compose/testdata/docker-compose-override.yml b/modules/compose/testdata/docker-compose-override.yml index b721aec403..3fcb135947 100644 --- a/modules/compose/testdata/docker-compose-override.yml +++ b/modules/compose/testdata/docker-compose-override.yml @@ -2,11 +2,6 @@ version: '3' services: nginx: image: docker.io/nginx:stable-alpine - environment: - bar: ${bar} - foo: ${foo} - ports: - - "9080:80" mysql: image: docker.io/mysql:8.0.36 environment: diff --git a/modules/compose/testdata/docker-compose-simple.yml b/modules/compose/testdata/docker-compose-simple.yml index 104f6c7484..ddb324cbf7 100644 --- a/modules/compose/testdata/docker-compose-simple.yml +++ b/modules/compose/testdata/docker-compose-simple.yml @@ -4,5 +4,6 @@ services: image: docker.io/nginx:stable-alpine environment: bar: ${bar} + foo: ${foo} ports: - "9080:80"