Commit Graph

15915 Commits

Author SHA1 Message Date
Hayato Kiwata
f078cebbd1 fix: propagate context deadline exceeded error properly
When a shim becomes unresponsive (e.g., stopped via SIGSTOP), ttrpc
communication times out with `context deadline exceeded`.

Currently, this error is not properly propagated, causing redundant API
calls and slow container listing by client sides.

Specifically, when executing the API to check the task state, it appears
that the `context deadline exceeded` error via ttrpc is not being handled
within `shimTask.State()` and `getProcessState()`.

As a result, when this error occurs, clients such as nerdctl cannot
recognize this error, and it is thought that the issue described below is
occurring:

- https://github.com/containerd/nerdctl/issues/4720

Therefore, this commit adds error handling to ensure timeouts are properly
handled by client sides.

Signed-off-by: Hayato Kiwata <dev@haytok.jp>
2026-01-26 22:58:28 +09:00
Maksym Pavlenko
89c7170db5 Merge pull request #12537 from elezar/gpu-flag-as-cdi
Map ctr --gpus requests to NVIDIA CDI device requests
2025-12-01 18:58:46 +00:00
Maksym Pavlenko
017ae819f6 Merge pull request #12606 from thaJeztah/otel_deprecations
core/runtime/v2: remove uses of otelgrpc.UnaryClientInterceptor
2025-12-01 18:57:45 +00:00
Derek McGowan
32a8a175fb Merge pull request #12601 from containerd/dependabot/go_modules/golang.org/x/crypto-0.45.0
build(deps): bump golang.org/x/crypto from 0.43.0 to 0.45.0
2025-12-01 17:11:50 +00:00
Derek McGowan
ca440a5716 Merge pull request #12603 from vvoland/update-runc-1.4
runc: Update runc binary to v1.4.0
2025-12-01 17:11:36 +00:00
Sebastiaan van Stijn
459a95287b core/runtime/v2: remove uses of otelgrpc.UnaryClientInterceptor
The otelgrpc.UnaryClientInterceptor and otelgrpc.StreamClientInterceptor
options were deprecated and removed in favor of NewClientHandler.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-12-01 14:32:11 +01:00
Paweł Gronowski
fbb42c2a4f runc: Update runc binary to v1.4.0
v1.4.0 is the first release of the 1.4 release branch which is now
encouraged by the maintainers.

This update includes a fix for a regression introduced in CVE-2025-52881
mitigation patches where the `mode=` argument was incorrectly applied to
tmpfs mounts regardless of whether the target path existed.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-12-01 11:44:29 +01:00
dependabot[bot]
8fcb918d02 build(deps): bump golang.org/x/crypto from 0.43.0 to 0.45.0
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.43.0 to 0.45.0.
- [Commits](https://github.com/golang/crypto/compare/v0.43.0...v0.45.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-version: 0.45.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-01 08:47:55 +00:00
Akihiro Suda
f37f951f56 Merge pull request #12545 from erofs/fixes
Avoid using redundant loop devices to run mkfs for mount manager tests.
2025-11-28 07:13:24 +00:00
Akihiro Suda
ddad4a8c4e Merge pull request #12528 from containerd/dependabot/go_modules/github.com/opencontainers/selinux-1.13.1
build(deps): bump github.com/opencontainers/selinux from 1.12.0 to 1.13.1
2025-11-27 18:46:14 +00:00
Mike Brown
e3ec509477 Merge pull request #12574 from klihub/devel/short-circuit-nil-adjustment
cri/nri: short-circuit nil adjustment.
2025-11-27 16:18:10 +00:00
Fu Wei
18fd11cd84 Merge pull request #12571 from containerd/dependabot/github_actions/actions/checkout-6.0.0
build(deps): bump actions/checkout from 5.0.1 to 6.0.0
2025-11-27 15:51:39 +00:00
dependabot[bot]
dfb8bffb9a build(deps): bump actions/checkout from 5.0.1 to 6.0.0
Bumps [actions/checkout](https://github.com/actions/checkout) from 5.0.1 to 6.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](93cb6efe18...1af3b93b68)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-27 10:15:08 -05:00
Fu Wei
e6c5b213e9 Merge pull request #12572 from containerd/dependabot/github_actions/github/codeql-action-4.31.5
build(deps): bump github/codeql-action from 4.31.3 to 4.31.5
2025-11-27 15:14:39 +00:00
Derek McGowan
2bc9bdbcc0 Merge pull request #12583 from crazy-max/dockerfile-go-version
ci(release): set GO_VERSION in Dockerfile
2025-11-27 14:48:31 +00:00
Krisztian Litkey
3a717c1756 cri/nri: short-circuit nil adjustment.
Skip processing early if we get a nil adjustment from NRI.

Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
2025-11-27 16:41:29 +02:00
Fu Wei
d8068c0272 Merge pull request #12579 from akhilerm/3.1.2-cgroups-update
bump containerd/cgroups to v3.1.2
2025-11-27 14:14:05 +00:00
CrazyMax
0eac0eeb19 ci(release): set GO_VERSION in Dockerfile
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-11-27 14:42:49 +01:00
Akhil Mohan
9d357f5b98 bump containerd/cgroups to v3.1.2
bump containerd/cgroups to fix hugetlb.events parse errors

Signed-off-by: Akhil Mohan <akhilerm@gmail.com>
2025-11-27 09:41:05 +05:30
dependabot[bot]
72b218ee7a build(deps): bump github.com/opencontainers/selinux
Bumps [github.com/opencontainers/selinux](https://github.com/opencontainers/selinux) from 1.12.0 to 1.13.1.
- [Release notes](https://github.com/opencontainers/selinux/releases)
- [Commits](https://github.com/opencontainers/selinux/compare/v1.12.0...v1.13.1)

---
updated-dependencies:
- dependency-name: github.com/opencontainers/selinux
  dependency-version: 1.13.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2025-11-27 13:10:41 +09:00
Fu Wei
fcf99b1273 Merge pull request #12578 from fuweid/update-windows-os
.github: skip 5 critest cases for window-2022
2025-11-27 03:31:05 +00:00
Wei Fu
13912cf3b4 .github: skip 5 critest cases in window CI pipeline
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2025-11-26 21:21:57 -05:00
Evan Lezar
f5cd8d56f4 Map ctr --gpus requests to NVIDIA CDI device requests
This change maps ctr --gpus requests to CDI device requests.
This is done by mapping --gpus ID to a nvidia.com/gpu=ID device
request.

This removes the dependence on the nvidia-container-cli and instead
uses existing CDI specifications for nvidia devices if available on
the system.

Signed-off-by: Evan Lezar <elezar@nvidia.com>
2025-11-25 11:22:22 +01:00
Fu Wei
612ecf84a1 Merge pull request #12573 from erofs/erofs-fixes
ci: use GitHub source for erofs-utils to fix network flakiness
2025-11-25 04:06:46 +00:00
Fu Wei
576b52aa33 Merge pull request #12561 from fuweid/fix-loopback-testcase
core/mount.test: should not call removeLoop when set autoclear
2025-11-25 02:49:34 +00:00
Gao Xiang
c1089f6ed6 ci: use GitHub source for erofs-utils
`git.kernel.org` is suffering from network flakiness so just use
github source for github workflows.

Also, upgrade erofs-utils to the latest version, 1.8.10.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
2025-11-25 10:32:42 +08:00
dependabot[bot]
5a104b9670 build(deps): bump github/codeql-action from 4.31.3 to 4.31.5
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.3 to 4.31.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](014f16e7ab...fdbfb4d275)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-24 23:29:09 +00:00
Wei Fu
a5c84021c8 core/mount: should not call removeLoop when set autoclear
In CI we run make root-test via gotestsum, which executes multiple
package tests concurrently. TestAutoclearTrueLoop attempts to invoke
LOOP_CLR_FD using a device name, which introduces a race condition.

Example race:

Process P1 represents mount.test which runs TestAutoclearTrueLoop
Process P2 represents manager.test which runs TestLoopbackMount

T1: P1 closes fd of loop-device (loop3) (kernel unsets backing-file on close)
T2: P2 gets loop3 from /dev/loop-control
T3: P2 configures loop3 with backing file successfully
T4: P1 invokes removeLoop to clear backing file for loop3

You might see that failure like this

```
=== FAIL: core/mount/manager TestLoopbackMount (0.05s)
    log_hook.go:47: time="2025-10-23T21:49:22.532811960Z" level=debug msg="activating mount" func="manager.(*mountManager).Activate" file="/home/runner/work/containerd/containerd/core/mount/manager/manager.go:134" mounts="[{loop /tmp/TestLoopbackMount989607109/001/fs-1621892597  []} {format/ext4 {{ mount 0 }}  []}]" name=id1 testcase=TestLoopbackMount
    helpers.go💯 unmount /tmp/TestLoopbackMount989607109/001/test-mount-3030342351
    manager_linux_test.go:80:
        	Error Trace:	/home/runner/work/containerd/containerd/core/mount/manager/manager_linux_test.go:80
        	            				/home/runner/work/containerd/containerd/core/mount/manager/manager_linux_test.go:105
        	Error:      	Received unexpected error:
        	            	failed to get loop device info: no such device or address
        	Test:       	TestLoopbackMount
```

To fix this, the test now compares backing-file's inode directly and does
not call removeLoop when autoclear is set.

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2025-11-23 21:31:08 -05:00
Maksym Pavlenko
bcc3b3b1af Merge pull request #12524 from containerd/dependabot/go_modules/golang-x-c99a2255a7
build(deps): bump the golang-x group across 1 directory with 3 updates
2025-11-20 19:41:03 +00:00
Maksym Pavlenko
5834b946b5 Merge pull request #12500 from containerd/dependabot/github_actions/softprops/action-gh-release-2.4.2
build(deps): bump softprops/action-gh-release from 2.4.1 to 2.4.2
2025-11-20 18:54:51 +00:00
Maksym Pavlenko
646351235c Merge pull request #12527 from containerd/dependabot/go_modules/k8s-879ccb9dde
build(deps): bump the k8s group with 3 updates
2025-11-20 18:07:25 +00:00
Akihiro Suda
8fa9f4aeb8 Merge pull request #12491 from andrey-noskov/fix-sas-token-leak
fix: redact all query parameters in CRI error logs
2025-11-19 21:46:59 +00:00
Akihiro Suda
18fcad8305 Merge pull request #12465 from containerd/dependabot/go_modules/github.com/containerd/cgroups/v3-3.1.1
build(deps): bump github.com/containerd/cgroups/v3 from 3.1.0 to 3.1.1
2025-11-19 21:33:16 +00:00
Andrey Noskov
3e2cee2bf1 fix: redact all query parameters in CRI error logs
Signed-off-by: Andrey Noskov <andreyn@microsoft.com>
2025-11-19 11:13:47 +01:00
dependabot[bot]
13b1f43712 build(deps): bump github.com/containerd/cgroups/v3 from 3.1.0 to 3.1.1
Bumps [github.com/containerd/cgroups/v3](https://github.com/containerd/cgroups) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/containerd/cgroups/releases)
- [Commits](https://github.com/containerd/cgroups/compare/v3.1.0...v3.1.1)

---
updated-dependencies:
- dependency-name: github.com/containerd/cgroups/v3
  dependency-version: 3.1.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2025-11-19 17:48:52 +09:00
Gao Xiang
190ed6b677 Avoid using redundant loop devices to run mkfs for mount manager tests.
mkfs.ext4 supports creating filesystems from regular files.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
2025-11-19 11:50:01 +08:00
Fu Wei
4ab5ee32ad Merge pull request #12525 from containerd/dependabot/github_actions/actions/checkout-5.0.1
build(deps): bump actions/checkout from 5.0.0 to 5.0.1
2025-11-18 23:56:30 +00:00
dependabot[bot]
e155f0a4bb build(deps): bump softprops/action-gh-release from 2.4.1 to 2.4.2
Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release) from 2.4.1 to 2.4.2.
- [Release notes](https://github.com/softprops/action-gh-release/releases)
- [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md)
- [Commits](6da8fa9354...5be0e66d93)

---
updated-dependencies:
- dependency-name: softprops/action-gh-release
  dependency-version: 2.4.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-18 11:24:56 -08:00
dependabot[bot]
dfc2e35b1d build(deps): bump the golang-x group across 1 directory with 3 updates
Bumps the golang-x group with 3 updates in the / directory: [golang.org/x/mod](https://github.com/golang/mod), [golang.org/x/sync](https://github.com/golang/sync) and [golang.org/x/sys](https://github.com/golang/sys).


Updates `golang.org/x/mod` from 0.29.0 to 0.30.0
- [Commits](https://github.com/golang/mod/compare/v0.29.0...v0.30.0)

Updates `golang.org/x/sync` from 0.17.0 to 0.18.0
- [Commits](https://github.com/golang/sync/compare/v0.17.0...v0.18.0)

Updates `golang.org/x/sys` from 0.37.0 to 0.38.0
- [Commits](https://github.com/golang/sys/compare/v0.37.0...v0.38.0)

---
updated-dependencies:
- dependency-name: golang.org/x/mod
  dependency-version: 0.30.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: golang-x
- dependency-name: golang.org/x/sync
  dependency-version: 0.18.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: golang-x
- dependency-name: golang.org/x/sys
  dependency-version: 0.38.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: golang-x
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-18 11:20:32 -08:00
dependabot[bot]
f2771359f9 build(deps): bump the k8s group with 3 updates
Bumps the k8s group with 3 updates: [k8s.io/apimachinery](https://github.com/kubernetes/apimachinery), [k8s.io/client-go](https://github.com/kubernetes/client-go) and [k8s.io/cri-api](https://github.com/kubernetes/cri-api).


Updates `k8s.io/apimachinery` from 0.34.1 to 0.34.2
- [Commits](https://github.com/kubernetes/apimachinery/compare/v0.34.1...v0.34.2)

Updates `k8s.io/client-go` from 0.34.1 to 0.34.2
- [Changelog](https://github.com/kubernetes/client-go/blob/master/CHANGELOG.md)
- [Commits](https://github.com/kubernetes/client-go/compare/v0.34.1...v0.34.2)

Updates `k8s.io/cri-api` from 0.34.1 to 0.34.2
- [Commits](https://github.com/kubernetes/cri-api/compare/v0.34.1...v0.34.2)

---
updated-dependencies:
- dependency-name: k8s.io/apimachinery
  dependency-version: 0.34.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
- dependency-name: k8s.io/client-go
  dependency-version: 0.34.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
- dependency-name: k8s.io/cri-api
  dependency-version: 0.34.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-18 11:20:09 -08:00
Maksym Pavlenko
f727879a2c Merge pull request #12530 from containerd/dependabot/go_modules/google.golang.org/grpc-1.77.0
build(deps): bump google.golang.org/grpc from 1.76.0 to 1.77.0
2025-11-18 19:19:45 +00:00
Maksym Pavlenko
be513d8199 Merge pull request #12526 from containerd/dependabot/github_actions/github/codeql-action-4.31.3
build(deps): bump github/codeql-action from 4.31.2 to 4.31.3
2025-11-18 18:45:49 +00:00
Maksym Pavlenko
c073fea338 Merge pull request #12529 from cpuguy83/revert_reader_at
Revert "Implement io.ReaderAt on docker fetch reader"
2025-11-18 18:45:02 +00:00
Maksym Pavlenko
4c32f5f73b Merge pull request #12531 from samuelkarp/ctr-dump-config
ctr run: dump OCI config to a file
2025-11-18 18:43:48 +00:00
Maksym Pavlenko
a1a6229699 Merge pull request #12532 from samuelkarp/ctr-rlimit-nofile
ctr: allow rlimit-nofile override
2025-11-18 18:41:13 +00:00
Fu Wei
8d0b648ad5 Merge pull request #12533 from dmcgowan/erofs-defaults-darwin
Fix image defaults on Darwin to usable configuration
2025-11-18 18:01:56 +00:00
Derek McGowan
c2b22d6bd6 Update the ctr pull defaults when using the transfer service
Match the defaults set by the transfer service which will configure
linux by default on darwin hosts.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-11-18 08:51:51 -08:00
Derek McGowan
487d77ff50 Fix transfer unpack defaults on darwin
Fix the default unpack configuration on darwin to a usable
configuration.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-11-18 08:51:51 -08:00
Derek McGowan
497f896d65 Update default differs on darwin
Use the erofs differ by default on darwin. This could be default for all
Unix platforms but limit the default changes to fix broken cases for backports.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-11-18 08:51:51 -08:00
Derek McGowan
49888e001f Use default writable size in erofs snapshotter for non-Linux hosts
Non-Linux hosts are not expected to be able to directly mount erofs
snapshotters on the host system. Non-Linux hosts should use block mode
by default with a reasonably set default block size.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-11-18 08:51:50 -08:00