Commit Graph

56805 Commits

Author SHA1 Message Date
Paweł Gronowski
f0546ad689 Merge pull request #52851 from thaJeztah/update_authors_mailmap
update AUTHORS and mailmap
2026-06-12 17:47:17 +02:00
Sebastiaan van Stijn
52231e73f7 update AUTHORS and mailmap
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-12 17:39:31 +02:00
Sebastiaan van Stijn
277d0f08d4 Merge pull request #52849 from vvoland/fix-dockerpy
test/docker-py: Fix swarm encrypted failure
2026-06-12 17:25:20 +02:00
Sebastiaan van Stijn
5ceb949240 Merge pull request #52821 from notandruu/daemon/rlkclient-loopback-simplify
libnet/rlkclient: simplify ChildHostIP loopback handling
2026-06-12 17:03:16 +02:00
Sebastiaan van Stijn
bf81e1d54e Merge pull request #52818 from mat007/portallocator-reserved-ports
daemon/libnetwork/portallocator: skip kernel-reserved ports
2026-06-12 17:02:42 +02:00
Sebastiaan van Stijn
a2bb71ad59 Merge pull request #52806 from takumi12311123/45233-add-timeout-minutes
gha: Set timeout-minutes on build-dind and labeler jobs
2026-06-12 16:51:48 +02:00
Takumi Akasaka
7e8d2d1c13 gha: Set timeout-minutes on build-dind and labeler jobs
These were the only two jobs running directly via `runs-on:` that did
not have a `timeout-minutes` guardrail. Add 120 minutes as a starting
point to prevent runaway jobs, matching the existing convention used
elsewhere in the workflows. Tuning each job's timeout to its usual
runtime is left as a follow-up, as suggested in the issue.

Signed-off-by: Takumi Akasaka <takumiakasaka1231@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-12 16:10:56 +02:00
Sebastiaan van Stijn
6f484306ab Merge pull request #52651 from acouvreur/fix/container-update-blkio-device-throttle
daemon: support per-device blkio throttle in ContainerUpdate
2026-06-12 16:04:38 +02:00
Sebastiaan van Stijn
53ecd322ff Merge pull request #52828 from thaJeztah/sync_api
api/swagger: sync changes to versioned copies
2026-06-12 16:01:47 +02:00
Paweł Gronowski
dc97f25cbf daemon/router: Gate ContainerUpdate blkio device fields by API version
ContainerUpdate only starts applying per-device blkio settings in the
current API version.

The fields existed in the Go request type before that because it shares
`container.Resources` with other endpoints, but they were not documented
as supported for container update and older daemons ignored them.

Clear these fields when handling requests for older API versions so
clients pinned to those versions keep the previous behavior, while v1.55
clients can use the newly supported fields.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 15:52:31 +02:00
Alexis Couvreur
ca30e0d8ec daemon: support per-device blkio throttle in ContainerUpdate
The POST /containers/{id}/update API accepts BlkioWeightDevice,
BlkioDeviceReadBps, BlkioDeviceWriteBps, BlkioDeviceReadIOps, and
BlkioDeviceWriteIOps in its Resources body, but these five fields were
silently ignored when updating a running container.

The root cause was in toContainerdResources (daemon/update_linux.go):
only BlkioWeight was mapped into specs.LinuxBlockIO; the per-device
fields were never converted, so tsk.UpdateResources never wrote to
cgroupv2 io.max or the cgroupv1 blkio throttle files.

Fix by calling the existing getBlkioWeightDevices and
getBlkioThrottleDevices helpers (already used in oci_linux.go for
container creation) to populate all five fields. The function signature
is extended to return an error so that stat(2) failures on invalid
device paths are surfaced to the caller instead of being silently
dropped.

The API makes distinction between nil and zero-length slices while
doing. A nil per-device blkio field means the caller did not request an
update for that setting, while a non-nil empty slice means the caller
explicitly requested the setting to be cleared.

The Windows stub is updated to match the new signature.

Signed-off-by: Alexis Couvreur <alexiscouvreur.pro@gmail.com>
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 15:52:14 +02:00
Paweł Gronowski
5eda928bb8 Merge pull request #52636 from smerkviladze/add-attestation-statements
image: expose in-toto attestation statements via the API
2026-06-12 15:49:34 +02:00
Paweł Gronowski
f3169f92a3 test/docker-py: Fix swarm encrypted failure
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 15:43:03 +02:00
Paweł Gronowski
4ee144f615 Merge pull request #52843 from vvoland/deflake-TestDiskUsage
integration/system: Allow rootless disk usage block drift
2026-06-12 15:38:57 +02:00
Sebastiaan van Stijn
57d28f76e5 Merge pull request #52835 from crazy-max/buildkit-0.31.0-rc2
vendor: update buildkit to v0.31.0-rc2
2026-06-12 15:30:15 +02:00
Paweł Gronowski
e362779c9e Merge pull request #52847 from vvoland/gha-fix-cancel
gha: Avoid cancelling non-PR CI runs
2026-06-12 15:13:02 +02:00
Andrew Liu
4e04377caa libnet/rlkclient: simplify ChildHostIP loopback handling
Follow-up to PR 52804, applying thaJeztah's review suggestion: check
IsLoopback first for both address families (preserving any requested
loopback address), and only fall back to the canonical loopback for
the family otherwise. No behavior change; ::1 now returns through the
loopback-preserving branch instead of the IPv6 fallback, with the same
result.

Signed-off-by: Andrew Liu <andrewjliu22@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-12 15:09:13 +02:00
Paweł Gronowski
17ccff865e gha: Avoid cancelling non-PR CI runs
The concurrency groups currently cancel older runs for push, tag,
scheduled, and manually dispatched events.

On maintained refs this canhide a regression when a later run starts
before the earlier validation finishes.

Keep cancellation for stale pull request runs only, while allowing
non-PR validation to complete.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 14:57:03 +02:00
Paweł Gronowski
f39fa9b651 integration/system: Extend rootless disk usage drift tolerance
Rootless snapshotter mode can report image TotalSize one filesystem
block above the per-image and reclaimable sizes after loading BusyBox.
The empty disk usage case already accepts this overlayfs accounting
artifact.

Allow the same bounded 4096-byte positive drift in the
after_LoadBusybox assertions while keeping strict equality for other
daemon modes.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 14:38:00 +02:00
Sebastiaan van Stijn
7d60710974 Merge pull request #52742 from AkihiroSuda/fix-52737
daemon: join detached netns when inspecting sysinfo
2026-06-12 14:37:03 +02:00
Sebastiaan van Stijn
e52ca97091 Merge pull request #52839 from thaJeztah/rm_stray_err_log
daemon: windows: remove stray error log on service shutdown
2026-06-12 14:32:37 +02:00
Sopho Merkviladze
0b2c3780be api: declare ImageAttestations platform and type as repeatable
Both query parameters are now collectionFormat: multi arrays in the
swagger so they can accept multiple values later without an API
version bump. The server still operates on a single platform and
rejects requests passing more than one; type is read directly as a
list of repeated values instead of a comma-separated string.

Signed-off-by: Sopho Merkviladze <smerkviladze@mirantis.com>
2026-06-12 16:20:52 +04:00
CrazyMax
c1ed6b6b2d vendor: update buildkit to v0.31.0-rc2
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-06-12 13:43:37 +02:00
Paweł Gronowski
953c592487 Merge pull request #52838 from vvoland/gha-cleanup-logs
Revert "gha/ci: Store slim test-results-* artifacts"
2026-06-12 13:25:05 +02:00
Sebastiaan van Stijn
99c81194be daemon: windows: remove stray error log on service shutdown
runDaemon would unconditionally send an error event if the daemon
was running as a system service;

    Run New-Item -ItemType Directory -Force -Path ".\bundles" | Out-Null
    2026-06-08T03:31:52.1865738Z [Information] Starting up
    2026-06-08T03:31:52.3160498Z [Information] OTEL tracing is not configured, using no-op tracer provider
    2026-06-08T03:31:52.5037110Z [Information] Windows default isolation mode: process
    2026-06-08T03:31:52.7212058Z [Information] Loading containers: start.
    2026-06-08T03:31:52.7345902Z [Information] [graphdriver] trying configured driver: windowsfilter
    2026-06-08T03:31:52.8920546Z [Information] Restoring containers: start.
    2026-06-08T03:31:52.9910057Z [Information] Restoring existing overlay networks from HNS into docker
    2026-06-08T03:31:53.8958218Z [Information] Loading containers: done.
    2026-06-08T03:31:53.9093383Z [Information] Docker daemon [storage-driver=windowsfilter containerd-snapshotter=false version=29.1.5 commit=3b01d641]
    2026-06-08T03:31:53.9103431Z [Information] Initializing buildkit
    2026-06-08T03:31:54.3243456Z [Information] Completed buildkit initialization
    2026-06-08T03:31:54.4878293Z [Information] Daemon has completed initialization
    2026-06-08T03:31:54.4881959Z [Information] API listen on //./pipe/docker_engine
    2026-06-08T03:47:45.7182269Z [Information] Processing signal 'terminated'
    2026-06-08T03:47:45.7203206Z [Information] Daemon shutdown complete
    Error: 2026-06-08T03:47:45.7206236Z [Error] <nil>

If debug was enabled, it would log this error twice (once as error, and once as debug).

Let's make this a single log, and only an error if there was one. Note that this may still
be redundant, as `daemonCLI.start` also logs this error;
4c19a01575/daemon/command/daemon.go (L127-L134)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-12 12:45:14 +02:00
Paweł Gronowski
3407385a86 Revert "gha/ci: Store slim test-results-* artifacts"
This reverts commit 79f5ddc271.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-12 12:23:55 +02:00
Mathieu Champlon
86626bb2ce daemon/libnetwork/portallocator: skip kernel-reserved ports
The allocator reads its bounds from net.ipv4.ip_local_port_range but
ignored net.ipv4.ip_local_reserved_ports, so dynamically allocated host
ports could land on ports the kernel itself would never hand out
automatically, typically ports set aside for other applications.

Skip those ports when allocating from the default ephemeral range,
mirroring the kernel behaviour for automatic port assignment. Requests
for a specific port or an explicit port range are unchanged, like
explicit binds are unchanged by ip_local_reserved_ports.

Signed-off-by: Mathieu Champlon <mathieu.champlon@docker.com>
2026-06-12 12:09:28 +02:00
Sopho Merkviladze
a0b6dbc2fc api: add GET /images/{name}/attestations endpoint
Add a new Engine API endpoint that returns the in-toto attestation
statements attached to an image for a given platform. The endpoint
locates the attestation manifest(s) referencing the requested platform's
image manifest, enumerates the statement layers, and returns each
layer's OCI descriptor (including media type, digest, size, and
annotations) together with its in-toto predicate type.

Query parameters:
  - platform: JSON-encoded OCI platform; defaults to the daemon's host
    platform if omitted.
  - type: comma-separated list of in-toto predicate type URIs; if
    omitted, all statements are returned.
  - statement: boolean, defaults to false. When true, the daemon reads
    each matching statement blob and includes the verbatim in-toto JSON
    in the response. When false (or omitted), statement blobs are not
    read and the Statement field is absent from each entry.

The manifest-chain walk (locating the platform image manifest and its
associated attestation manifest) is delegated to policy-helpers'
image.ResolveSignatureChain so that moby and BuildKit agree on how to
interpret the attestation storage format. The statement-layer iteration
and blob reading is inlined: when statement bodies are requested it
fails fast on the first unreadable blob and reads matching blobs
eagerly into memory; otherwise statement-layer blobs are never read
from the content store.

The endpoint is implemented for the containerd image store. The legacy
graphdriver store returns errdefs.NotImplemented (HTTP 501).

Signed-off-by: Sopho Merkviladze <smerkviladze@mirantis.com>
2026-06-12 13:40:58 +04:00
Paweł Gronowski
d244804641 Merge pull request #52832 from renovate-bot/renovate/aws-sdk-go-v2-monorepo
Update aws-sdk-go-v2 monorepo to v1.75.2
2026-06-12 10:51:01 +02:00
Sebastiaan van Stijn
b70710150a Merge pull request #52820 from corhere/libnftables-without-nft
libnetwork: don't depend on `nft` when linked against libnftables
2026-06-11 23:53:04 +02:00
Mend Renovate
d6d4f958bc Update aws-sdk-go-v2 monorepo to v1.75.2
Signed-off-by: Mend Renovate <bot@renovateapp.com>
2026-06-11 18:37:52 +00:00
Sebastiaan van Stijn
ab27417d32 Merge pull request #52831 from vvoland/work-api
api: Bump to 1.55
2026-06-11 20:23:30 +02:00
Paweł Gronowski
8e54f4f249 Add replace rules
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-11 20:14:29 +02:00
Sebastiaan van Stijn
e38b8f7a1f Merge pull request #52829 from vvoland/gha-refactor-test
gha/ci: Simplify test job name
2026-06-11 20:00:22 +02:00
Paweł Gronowski
2badd7ece3 api: Bump to 1.55
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-11 19:37:35 +02:00
Paweł Gronowski
29f6cd5c90 Merge pull request #41963 from thaJeztah/prefix_slash
testing: refactor uses of "getPrefixAndSlashFromDaemonPlatform()"
2026-06-11 17:33:42 +02:00
Paweł Gronowski
79b55da537 gha/ci: Simplify test job name
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-11 17:30:43 +02:00
Paweł Gronowski
0a3aa0bc0c Merge pull request #52732 from vvoland/gha-refactor-test
gha/test: Extract mode selection to the caller
2026-06-11 17:21:16 +02:00
Paweł Gronowski
d54342afab Merge pull request #52814 from vvoland/buildkit-fix-gc
builder-next: Fix Buildkit GC filter
2026-06-11 17:10:32 +02:00
Sebastiaan van Stijn
bff5b9cf84 api/swagger: sync swarm join endpoint to older docs versions
Syncs changes from 2ecaac9631
and d5f6bdb027 to older API
versions, in addition to formatting changes.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-11 15:38:04 +02:00
Sebastiaan van Stijn
8368bcd28f api/swagger: move position of ImageInspect.Identity
commit 6d133c5ec6 moved this field in
the swagger; move it back to align with older API versions.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-11 15:37:38 +02:00
Paweł Gronowski
0538c9a1b8 builder-next: Fix Buildkit GC filter matching
Split the default GC policy filter into separate selectors so containerd
filters OR the intended reproducible cache types instead of ANDing
mutually exclusive record types.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-06-11 14:06:32 +02:00
Paweł Gronowski
ada941fe1c Merge pull request #52826 from thaJeztah/skip_daemon_logs
gha: windows: skip "Daemon event logs" if starting daemon was skipped
2026-06-11 13:30:20 +02:00
Sebastiaan van Stijn
7442fed14b Merge pull request #52825 from thaJeztah/skip_otel_stop
gha: windows: skip "Stop OpenTelemetry Collector" if it wasn't started
2026-06-11 12:48:20 +02:00
Cory Snider
8e3e9f4cf9 d/libn/i/nftables: cgo nftables without nft cmd
When the daemon is linked against libnftables it programs the kernel
without invoking the `nft` command. Allow the nftables firewall backend
to be enabled when libnftables is used, irrespective of whether `nft` is
installed on the host.

Update the bridge network driver to clean up stale nftables tables in
iptables mode without depending on the `nft` command.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2026-06-11 10:54:46 +02:00
Cory Snider
d27169cf3f d/libn/i/nftables: decouple nft handle from table
Afford applying nft commands via libnftables without needing to go
through our table abstraction. Make the table abstraction responsible
for lazily allocating an nft context.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2026-06-11 10:54:43 +02:00
Akihiro Suda
a2b90c7cee daemon: join detached netns when inspecting sysinfo
Join `$ROOTLESSKIT_STATE_DIR/netns` when inspecting
`net.ipv4.ip_forward`, to silence the bogus warning
"IPv4 forwarding is disabled".

Fix issue 52737

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2026-06-11 17:41:34 +09:00
Akihiro Suda
efe6156e19 daemon: allow RawSysInfo to return an error
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2026-06-11 17:39:03 +09:00
Sebastiaan van Stijn
bca0598b7f Merge pull request #52817 from tonistiigi/update-buildkit-v0.31.0-rc1
vendor: update buildkit to v0.31.0-rc1
2026-06-11 09:56:44 +02:00
Sebastiaan van Stijn
a6ca4babd2 gha: windows: skip "Daemon event logs" if starting daemon was skipped
This step would fail if the daemon was never started ("Starting test daemon"),
or failed to start;

    Run Get-WinEvent -ea SilentlyContinue `
    out-file: D:\a\_temp\2b911acb-4e0e-4684-bf63-606f0da5f7c6.ps1:2
    Line |
       2 |  Get-WinEvent -ea SilentlyContinue `
         |  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         | Could not find a part of the path 'D:\a\moby\moby\go\src\github.com\docker\docker\bundles\daemon.log'.
    Error: Process completed with exit code 1.

- Update the step to skip if we never attempted to start the daemon
- Make sure the output directory is created: even if we failed to start
  the daemon (and thus tests weren't run), the startup itself could
  potentially contain information that helps debugging the reason for
  the daemon starting.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-11 09:48:55 +02:00