Commit Graph

11900 Commits

Author SHA1 Message Date
Sebastiaan van Stijn d719b416ab Merge pull request #6500 from thaJeztah/bump_go_events
vendor: github.com/docker/go-events v0.0.0-20250808211157-605354379745
2025-09-25 18:42:17 +02:00
Sebastiaan van Stijn 008b2df526 Merge pull request #6499 from thaJeztah/bump_swarmkit
vendor: github.com/moby/swarmkit/v2 v2.1.0
2025-09-25 18:41:50 +02:00
Sebastiaan van Stijn 96732f858a Merge pull request #6498 from thaJeztah/bump_jose
vendor: github.com/go-jose/go-jose/v4 v4.1.2
2025-09-25 18:41:17 +02:00
Sebastiaan van Stijn 6d1c037640 vendor: github.com/docker/go-events v0.0.0-20250808211157-605354379745
full diff: https://github.com/docker/go-events/compare/c867878c5e32...605354379745

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 15:13:31 +02:00
Sebastiaan van Stijn 9cba658e9a vendor: github.com/moby/swarmkit/v2 v2.1.0
full diff: https://github.com/moby/swarmkit/compare/v2.0.0...v2.1.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 15:07:05 +02:00
Sebastiaan van Stijn 57314d42a2 vendor: github.com/go-jose/go-jose/v4 v4.1.2
full diff: https://github.com/go-jose/go-jose/compare/v4.0.5...v4.1.2

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 14:58:11 +02:00
Sebastiaan van Stijn e922dbefca vendor: golang.org/x/crypto v0.39.0
no changes in vendored files

full diff: https://github.com/golang/crypto/compare/v0.37.0...v0.39.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 14:58:05 +02:00
Sebastiaan van Stijn 286658d7ff vendor: golang.org/x/text v0.26.0
no changes in vendored files

full diff: https://github.com/golang/text/compare/v0.24.0...v0.26.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 14:55:03 +02:00
Sebastiaan van Stijn 90959c40bd vendor: golang.org/x/term v0.32.0
full diff: https://github.com/golang/term/compare/v0.31.0...v0.32.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 14:54:18 +02:00
Paweł Gronowski f369c5bcf2 Merge pull request #6496 from thaJeztah/deprecate_apply
cli/command: deprecate DockerCli.Apply
2025-09-25 12:29:19 +00:00
Sebastiaan van Stijn 24bfedf3f8 cli/command: deprecate DockerCli.Apply
The Apply method was added when CLI options for constructing the CLI were
rewritten into functional options in [cli@7f207f3]. There was no mention
in the pull request of this method specifically, and this may have been
related to work being done elsewhere on compose-on-kubernetes or the
compose-cli plugin that may have needed options to modify the CLI config
after it was already initialized.

The CLI itself no longer depends on this method since [cli@133279f], and
the only known consumer (docker compose) no longer needs it since [cli@2711800]
and [cli@048e931].

This patch deprecates the method with the intent to remove it in a future
release.

[cli@7f207f3]: https://github.com/docker/cli/commit/7f207f3f957ed3f5129aeb22bef2a429c14caf22
[cli@133279f]: https://github.com/docker/cli/commit/133279fb0d4adea30d27d27eb8789b79405fc82b
[cli@2711800]: https://github.com/docker/cli/commit/271180043066ec1baaa91351a63f1854667171d4
[cli@048e931]: https://github.com/docker/cli/commit/048e931b422a6baa26d12f818bbb14c501164c09

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 13:27:28 +02:00
Paweł Gronowski ef3c19a80b Merge pull request #6494 from thaJeztah/deprecate_ContentTrustEnabled
cli/command: deprecate DockerCli.ContentTrustEnabled
2025-09-25 11:24:05 +00:00
Sebastiaan van Stijn 11d40488dd cli/command: deprecate DockerCli.ContentTrustEnabled
This function was used internally, but is no longer used. Users should check
the value of the `DOCKER_CONTENT_TRUST` environment variable instead.

There are no known external users of this method, so already removing it
from the Cli interface; this method will be removed in the next release.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 12:45:13 +02:00
Sebastiaan van Stijn 1bae6aafa8 trust: add internal utility for checking DOCKER_CONTENT_TRUST
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 12:45:08 +02:00
Sebastiaan van Stijn 1ace9aec34 cli/command: don't use DCT status for trust stub-flags
This is a follow-up to 7609dde8d0 and
3f5b1bdd32, which removed support for
DCT for build and plugin commands.

As these flags are just stubs, hidden by default and no longer functional,
they don't have to reflect the current state of DCT.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 12:39:28 +02:00
Paweł Gronowski 734328eef9 Merge pull request #6492 from thaJeztah/fix_alpine
e2e: update openssh, openssl to work around openssh bug
2025-09-25 11:39:52 +02:00
Paweł Gronowski 9c88b315ef Merge pull request #6488 from thaJeztah/deprecate_dct_opts
cli/command: deprecate WithContentTrustFromEnv, WithContentTrust
2025-09-25 11:31:55 +02:00
Paweł Gronowski 04bfe7dc78 Merge pull request #6490 from thaJeztah/deprecate_defaultversion
cli/command: deprecate DockerCli.DefaultVersion
2025-09-25 11:31:27 +02:00
Sebastiaan van Stijn b611f288ee e2e: update openssh, openssl to work around openssh bug
relates to https://gitlab.alpinelinux.org/alpine/aports/-/issues/17547

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 10:57:14 +02:00
Sebastiaan van Stijn 40cdfc0d81 cli/command: deprecate WithContentTrustFromEnv, WithContentTrust
These options were used internally as defaults for the constructor and
only impact commands implemented in the CLI itself.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 09:57:28 +02:00
Sebastiaan van Stijn 0270b2d6f7 cli/command: deprecate DockerCli.DefaultVersion
This function was used internally, but is no longer used. There are
no known users of this method, so already removing it from the Cli
interface.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-25 09:38:46 +02:00
Austin Vazquez 903e9b3426 Merge pull request #6453 from thaJeztah/rm_deprecated_template
templates: remove deprecated NewParse function
2025-09-24 10:40:45 -07:00
Paweł Gronowski a44144e1db Merge pull request #6479 from thaJeztah/plugin_semverish
cli-plugins/manager: allow schema-versions <= 2.0.0
2025-09-24 19:25:43 +02:00
Paweł Gronowski ed7908e4ed Merge pull request #4574 from milas/cli-user-agent
cli/command: add WithUserAgent option
2025-09-24 19:16:38 +02:00
Milas Bowman 048e931b42 cli/command: add WithUserAgent option
Add support to the `cli/command` package to accept a custom User
Agent to pass to the underlying client.

This is used as the `UpstreamClient` portion of the `User-Agent`
when the Moby daemon makes requests.

For example, pushing and pulling images with Compose might result
in the registry seeing a `User-Agent` value of:

```
docker/24.0.7 go/go1.20.10 git-commit/311b9ff kernel/6.5.13-linuxkit os/linux arch/arm64 UpstreamClient(docker-cli-plugin-compose/v2.24.0)
```

Signed-off-by: Milas Bowman <milas.bowman@docker.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 17:43:41 +02:00
Sebastiaan van Stijn ec912e5524 cli-plugins/manager: allow schema-versions <= 2.0.0
The CLI currently hard-codes the schema-version for CLI plugins to
"0.1.0", which doesn't allow us to expand the schema for plugins.

As there's many plugins that we shipped already, we can't break
compatibility until we reach 2.0.0, but we can expand the schema
with non-breaking changes.

This patch makes the validation more permissive to allow new schema
versions <= 2.0.0. Note that existing CLIs will still invalidate
such versions, so we cannot update the version until such CLIs are
no longer expected to be used, but this patch lays the ground-work
to open that option.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 16:17:33 +02:00
Austin Vazquez 8fbb70ae56 Merge pull request #6475 from thaJeztah/cli_plugin_options
cli-plugins/plugin: Run: allow customizing the CLI
2025-09-24 07:15:24 -07:00
Paweł Gronowski f3687d8a8b Merge pull request #5922 from thaJeztah/ignore_broken_symlinks
cli-plugins/manager: ignore broken symlinks
2025-09-24 15:10:23 +02:00
Sebastiaan van Stijn 9b2f831452 cli-plugins/manager: ignore broken symlinks
Before this patch, a broken symlink would print a warning;

    docker info > /dev/null
    WARNING: Plugin "/Users/thajeztah/.docker/cli-plugins/docker-feedback" is not valid: failed to fetch metadata: fork/exec /Users/thajeztah/.docker/cli-plugins/docker-feedback: no such file or directory

After this patch, such symlinks are ignored:

    docker info > /dev/null

With debug enabled, we don't ignore the faulty plugin, which will
make the warning shown on docker info;

    mkdir -p ~/.docker/cli-plugins
    ln -s nosuchplugin ~/.docker/cli-plugins/docker-brokenplugin
    docker --debug info
    Client:
     Version:    29.0.0-dev
     Context:    default
     Debug Mode: true
     Plugins:
      buildx: Docker Buildx (Docker Inc.)
        Version:  v0.25.0
        Path:     /usr/libexec/docker/cli-plugins/docker-buildx
    WARNING: Plugin "/Users/thajeztah/.docker/cli-plugins/docker-brokenplugin" is not valid: failed to fetch metadata: fork/exec /Users/thajeztah/.docker/cli-plugins/docker-brokenplugin: no such file or directory

    # ...

We should als consider passing a "seen" map to de-duplicate entries.
Entries can be either a direct symlink or in a symlinked path (for
which we can filepath.EvalSymlinks). We need to benchmark the overhead
of resolving the symlink vs possibly calling the plugin (to get their
metadata) further down the line.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 14:32:37 +02:00
Sebastiaan van Stijn 2711800430 cli-plugins/plugin: Run: allow customizing the CLI
Currently, the plugin.Run command constructs the DockerCli using
the default options, assuming plugins run with all the same options
as the CLI itself; to customize the CLI there's a "Apply" option,
but this means mutating the CLI after it's already constructed, which
is not ideal.

This patch adds a variadic ops argument to allow CLI plugins to pass
custom options to use for the CLI, so that there's no need to mutate
its config in most cases.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 14:17:15 +02:00
Sebastiaan van Stijn 84520653d8 templates: remove deprecated NewParse function
This was deprecated in 7ab3e7e774 and
no longer used.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 14:08:27 +02:00
Sebastiaan van Stijn c8600e1cea Merge pull request #6463 from thaJeztah/remove_oauth_escape_hatch
remove DOCKER_CLI_DISABLE_OAUTH_LOGIN escape hatch
2025-09-24 13:43:42 +02:00
Paweł Gronowski 4a4043cdb6 Merge pull request #6462 from thaJeztah/rm_deprecated_registryclient
remove deprecated cli/registry/client package
2025-09-24 13:18:58 +02:00
Paweł Gronowski 7cc801d93d Merge pull request #6467 from thaJeztah/no_apply
cli/command: NewDockerCli: don't depend on DockerCli.Apply
2025-09-24 13:17:51 +02:00
Paweł Gronowski 7afda4c6c5 Merge pull request #6468 from thaJeztah/cli_plugins_touchup
cli-plugins/plugin: Run: touch-up godoc and minor cleanups
2025-09-24 13:17:38 +02:00
Paweł Gronowski 550d40f7bc Merge pull request #6466 from thaJeztah/registry_3
e2e: use registry v3
2025-09-24 13:17:23 +02:00
Paweł Gronowski 5710de6d9a Merge pull request #6461 from thaJeztah/bump_xx
Dockerfile: update xx to v1.7.0
2025-09-24 13:17:13 +02:00
Paweł Gronowski 93bb8a7a0a Merge pull request #6458 from thaJeztah/bump_engine
vendor: github.com/moby/moby/api, github.com/moby/moby/client master
2025-09-24 13:16:39 +02:00
Paweł Gronowski b1d45285ba Merge pull request #6464 from thaJeztah/remove_deprecated_experimental
cli/config/configfile: remove deprecated ConfigFile.Experimental field
2025-09-24 13:15:54 +02:00
Paweł Gronowski 4c802a1548 Merge pull request #6465 from thaJeztah/rm_23_test
gha: update test-matrix: remove docker 23.x, 26.x, add 25.x
2025-09-24 13:15:27 +02:00
Sebastiaan van Stijn 635a718209 cli-plugins/plugin: Run: touch-up godoc and minor cleanups
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 12:57:42 +02:00
Sebastiaan van Stijn 133279fb0d cli/command: NewDockerCli: don't depend on DockerCli.Apply
The Apply method was added when CLI options for constructing the CLI were
rewritten into functional options in [cli@7f207f3]. There was no mention
in the pull request of this method specifically, and this may have been
related to work being done elsewhere on compose-on-kubernetes or the
compose-cli plugin that may have needed options to modify the CLI config
after it was already initialized.

We should try to remove functions that mutate the CLI configuration after
initialization if possible (and likely remove the `Apply` method); currently
this function is used in docker compose, but as part of a hack that can
probably be avoided.

[cli@7f207f3]: https://github.com/docker/cli/commit/7f207f3f957ed3f5129aeb22bef2a429c14caf22

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 12:10:57 +02:00
Sebastiaan van Stijn daa15c3bfa e2e: use registry v3
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 10:28:42 +02:00
Sebastiaan van Stijn 83e40c39b4 gha: update test-matrix: remove docker 23.x, 26.x, add 25.x
- Mirantis Container Runtime (MCR) 23.0 reached EOL, and the next LTS
  version of MCR is 25.x
- Docker 26.x reached EOL and is no longer maintained

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-24 10:12:05 +02:00
Sebastiaan van Stijn 71f46056c9 remove DOCKER_CLI_DISABLE_OAUTH_LOGIN escape hatch
This code was added in 846ecf59ff as an
escape hatch in case the new OAuth login flow would cause problems.
We have not received reports where the new flow caused problems, and
searching the internet shows no mentions of the env-var.

This env-var was not documented, so we can remove it.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-23 21:47:30 +02:00
Sebastiaan van Stijn a53e83a3d4 cli/config/configfile: remove deprecated ConfigFile.Experimental field
Configuration options for experimental CLI features were deprecated in
docker 19.03 (3172219932), and enabled by
default since docker 20.10 (977d3ae046).

This field was deprecated in c8f9187157,
which is part of the 28.x release, and is unused. This patch removes
the field.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-23 21:43:14 +02:00
Sebastiaan van Stijn 083e5ce872 cli/command/registry: remove deprecated OauthLoginEscapeHatchEnvVar
This const was added in 846ecf59ff, but
only used internally; commit 18cdc25bb4
deprecated the const, which was included in the 28.4 release.

This patch removes the exported const, as it's unused.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-23 21:31:43 +02:00
Sebastiaan van Stijn 3cf005ec91 remove deprecated cli/registry/client package
This package was deprecated in 13010ba673,
and only used internally. The deprecation was included in the 28.4 release,
and there's no known external users, so we can remove it for v29.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-23 21:21:31 +02:00
Sebastiaan van Stijn c5cbb3e648 vendor: github.com/moby/moby/api, github.com/moby/moby/client master
full diffs:

- https://github.com/moby/moby/compare/api/v1.52.0-beta.1...e98849831fc4e35bdc09ed31b85f91caa87a0103
- https://github.com/moby/moby/compare/client/v0.1.0-beta.0...e98849831fc4e35bdc09ed31b85f91caa87a0103

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-09-23 21:11:17 +02:00
Sebastiaan van Stijn e241f53ebc Merge pull request #6460 from thaJeztah/no_pause
deprecate "--pause" flag on docker commit in favor of "--no-pause"
2025-09-23 12:54:15 +02:00