Commit Graph

14496 Commits

Author SHA1 Message Date
Derek McGowan
740097573a
Merge pull request #8993 from estesp/update-releases
Update to latest releases in RELEASES.md
2023-08-21 09:16:45 -07:00
Phil Estes
7ad0a6ccfa
Update to latest releases in RELEASES.md
Since a recent contributor edited the synced version of this in the website (containerd.io) repo, we should just update the main repo and let the auto-sync PR get these 2 files back in sync with the latest releases.

Signed-off-by: Phil Estes <estesp@amazon.com>
2023-08-21 09:19:34 -04:00
Jin Dong
cd8c8ae4bc Remove hashicorp/go-multierror
Signed-off-by: Jin Dong <jin.dong@databricks.com>
2023-08-20 17:59:45 -07:00
Phil Estes
89553637a7
Merge pull request #8936 from oss-qm/submit/install-doc
Makefile: add rule for installing documentation
2023-08-19 18:47:00 -04:00
Phil Estes
7c850bac2e
Merge pull request #8974 from oss-qm/submit/metrics_unused_retval
ctr: metrics: drop unused retval from printWindowsStats()
2023-08-19 18:45:19 -04:00
Enrico Weigelt, metux IT consult
1571a5aa07 ctr: metrics: drop unused retval from printWindowsStats()
The error return value is always nil, so we don't need it at all.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2023-08-19 15:33:40 +02:00
Enrico Weigelt, metux IT consult
7063ae1f6c Makefile: add rule for installing documentation
Distros usually like to install docs, so add a rule for that, so
dist maintainers don't need to care about the details.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2023-08-19 15:32:29 +02:00
Danny Canter
de4c338ab5 Docs: Document proxy plugin diff support
Document that differs can be proxy plugins now.

Signed-off-by: Danny Canter <danny@dcantah.dev>
2023-08-18 17:55:54 -07:00
Derek McGowan
465c04c289
Merge pull request #8946 from lengrongfu/feat/bump-client-go
bump client-go v0.26.4
2023-08-18 16:35:24 -07:00
Akihiro Suda
4033add994
Merge pull request #8957 from AkihiroSuda/go-1.21
Go 1.21.0
2023-08-19 02:51:58 +09:00
Kazuyoshi Kato
3c8981a365
Merge pull request #8913 from oss-qm/submit/optional-systemd
cmd: containerd: allow building w/o systemd notify
2023-08-18 10:26:46 -07:00
Kazuyoshi Kato
bb1c855e62
Merge pull request #8964 from akhramov/feature/specify-default-freebsd-runtime
FreeBSD: set default runtime
2023-08-18 10:23:13 -07:00
Kazuyoshi Kato
742762b391
Merge pull request #8975 from oss-qm/submit/cri_unused_retvals
cri: spec_linux: drop unused retvals
2023-08-18 10:21:54 -07:00
Rodrigo Campos
d09f7cbe00 cri: Fix sandbox_mode "shim"
This is a partial revert of "cri/sbserver: Use platform instead of GOOS
for userns detection".

While what that commit did is 100% the right thing to do, when the
sandbox_mode is "shim" all controller.XXX() calls are RPCs and the
controller.Create() call initializes the controller. Therefore, things
like "getSandboxController()" don't work in the case of "shim"
sandbox_mode until after the controller.Create().

Due to this asymmetry and the lack of tests for shim mode, we didn't
catch it before.

This patch just reverts that commit so that the Create() and
getSandboxController() calls remain where they were, and just relies on
the config Linux section as a hack to detect if the pod sandbox will use
user namespaces or not.

Signed-off-by: Rodrigo Campos <rodrigoca@microsoft.com>
2023-08-18 15:13:10 +02:00
Enrico Weigelt, metux IT consult
60b2cb143f cmd: containerd: allow building w/o systemd notify
Make the rather obscure systemd notification build-time optional by
setting 'no_systemd' tag and so skip dependencies on around 9kLoC
vendor code.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2023-08-18 13:24:08 +02:00
Fu Wei
0f5dea3cc0
Merge pull request #8734 from djdongjin/content-copy-dedup
Simplify `content.Copy` logic
2023-08-18 11:05:27 +08:00
Robbie Buxton
23c95359aa Add WithMetaStore to overlay snapshotter to allow bringing your own
Signed-off-by: Robbie Buxton <138501839+rbpdt@users.noreply.github.com>
2023-08-17 19:28:44 +01:00
Enrico Weigelt, metux IT consult
0c1ad52eac cri: spec_linux: drop unused retvals
cgroupv1HasHugetlb() and cgroupv2HasHugetlb() may return errors, but nobody
(there's just one call site anyways) ever cares. So drop the unnecessary code.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2023-08-17 18:52:37 +02:00
Samuel Karp
3b32d3c6f2
Merge pull request #8922 from lengrongfu/feat/sync-image-action
feat: replace mcr.microsoft.com registry to ghcr.io/containerd registry
2023-08-17 00:59:46 -07:00
Akihiro Suda
eacd74c2b0
Go 1.21.0
https://go.dev/doc/go1.21

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-17 16:54:01 +09:00
Akihiro Suda
5756cb00e7
CI: increase timeout for Binaries
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-17 16:54:01 +09:00
Nashwan Azhari
c883410c96
CI: Explicitly upgrade MinGW on Windows 2019 GitHub runners.
The default version of MinGW and GCC on the GitHub-hosted Windows 2019
runners compile fine but lead to linker errors during runtime.

Signed-off-by: Nashwan Azhari <nazhari@cloudbasesolutions.com>
2023-08-17 16:52:51 +09:00
Akihiro Suda
0f043ae434
seccomp, apparmor: add go:noinline
Tests in pkg/cri/[sb]server/container_create_linux_test.go depends on go:noinline
since Go 1.21.

e.g.,
> ```
> === FAIL: pkg/cri/sbserver TestGenerateSeccompSecurityProfileSpecOpts/should_set_default_seccomp_when_seccomp_is_runtime/default (0.00s)
>     container_create_linux_test.go:1013:
>         	Error Trace:	/home/runner/work/containerd/containerd/pkg/cri/sbserver/container_create_linux_test.go:1013
>         	Error:      	Not equal:
>         	            	expected: 0x263d880
>         	            	actual  : 0x263cbc0
>         	Test:       	TestGenerateSeccompSecurityProfileSpecOpts/should_set_default_seccomp_when_seccomp_is_runtime/default
> ```

See comments in PR 8957.

Thanks to Wei Fu for analyzing this.

Co-authored-by: Wei Fu <fuweid89@gmail.com>
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-17 16:52:51 +09:00
Akihiro Suda
5d9bf7d139
CI: temporarily disable ci_fuzz due to incompatibility with recent Go
> github.com/containerd/containerd/contrib/apparmor
> github.com/containerd/containerd/contrib/apparmor
> Running go-fuzz -tags gofuzz -func FuzzLoadDefaultProfile -o fuzz_FuzzLoadDefaultProfile.a github.com/containerd/containerd/contrib/apparmor
> /usr/bin/ld: /usr/bin/ld: DWARF error: invalid or unhandled FORM value: 0x25
> fuzz_FuzzLoadDefaultProfile.a(000021.o): in function `_cgo_9c8efe9babca_C2func_res_search':
> cgo_unix_cgo_res.cgo2.c:(.text+0x32): undefined reference to `__res_search'
> /usr/bin/ld: fuzz_FuzzLoadDefaultProfile.a(000021.o): in function `_cgo_9c8efe9babca_Cfunc_res_search':
> cgo_unix_cgo_res.cgo2.c:(.text+0x81): undefined reference to `__res_search'
> clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
> 2023-08-11 14:25:45,433 - root - ERROR - Building fuzzers failed.
> 2023-08-11 14:25:45,433 - root - ERROR - Error building fuzzers for (commit: 432d86b87f75cc8ddf8f8101a5540eb206ffc894, pr_ref: refs/pull/8957/merge).

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-17 16:52:48 +09:00
Fu Wei
ba852faf41
Merge pull request #8954 from fuweid/fix-shim-leak 2023-08-17 08:16:20 +08:00
Fu Wei
a3c68d161f
Merge pull request #8778 from kiashok/stableABI_WindowsMatcher
Invoke stable ABI compliant platform check in windows matcher
2023-08-16 19:14:22 +08:00
Kirtana Ashok
e2ce4f58f6 Populate commit memory for windows memory usage stats
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2023-08-15 16:48:22 -07:00
Kirtana Ashok
823e0420eb Fix transfer service dependencies:
- Fill OSVersion field of ocispec.Platform for windows OS in
transfer service plugin init()
- Do not return error from transfer service ReceiveStream if
stream.Recv() returned context.Canceled error

Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2023-08-15 15:32:51 -07:00
Kirtana Ashok
cfb30a31a8 Invoke Stable ABI compatibility function in windows platform matcher
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2023-08-15 12:52:11 -07:00
Artem Khramov
0cea317a52
FreeBSD: set default runtime
@samuelkarp's https://github.com/samuelkarp/runj is a de facto default
FreeBSD runtime.

This change creates a set of defaults for FreeBSD setting
`wtf.sbk.runj.v1` as the default runtime.

Signed-off-by: Artem Khramov <akhramov@pm.me>
2023-08-14 22:44:21 +03:00
Fu Wei
36b871955c
Merge pull request #8930 from AkihiroSuda/rocky8.8 2023-08-14 20:44:20 +08:00
Akihiro Suda
5e051f5c6c
Merge pull request #8955 from AkihiroSuda/runc-1.1.9
update runc to v1.1.9
2023-08-14 20:30:23 +09:00
Danny Canter
def5ff3c4b Sandbox: Add annotations to controller CreateOptions
Following the addition of annotations to the grpc/ttrpc API surface,
follow suit with adding annotations to the controller api surface.

Signed-off-by: Danny Canter <danny@dcantah.dev>
2023-08-12 01:39:31 -07:00
Danny Canter
939ccbed42 Sandbox: Add annotations to CreateSandbox surface
An oft employed scheme for a lot of our APIs is to include an
annotations field which is just a map of string to string. This
usually allows folks using the API to send over metadata or auxiliary
information without needing to get a new field added (especially where
the field might not make sense for it to be a standalone field). I think
having annotations for CreateSandbox make sense for this same use case.

Signed-off-by: Danny Canter <danny@dcantah.dev>
2023-08-12 01:39:29 -07:00
Artem Khramov
1fd3a46526
archive/tarheader: fix FreeBSD hdr for regular files
This update addresses an issue where the stat call on FreeBSD could
return -1 for regular files. This led to incorrect Devmajor and
Devminor values, which should be zero in such cases. Refer to the
discussion on this bug in the following PR:
https://github.com/containerd/containerd/pull/5991.

The code change now handles this scenario appropriately.

Signed-off-by: Artem Khramov <akhramov@pm.me>
2023-08-11 23:50:08 +03:00
Akihiro Suda
f8edd5555f
update runc binary to v1.1.9
https://github.com/opencontainers/runc/releases/tag/v1.1.9

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-11 21:25:56 +09:00
Akihiro Suda
f35d1f08ec
go.mod: github.com/opencontainers/runc v1.1.9
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-11 21:25:29 +09:00
Wei Fu
00ef8ba99b Vagrantfile: add strace tool
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-11 18:22:44 +08:00
Wei Fu
601699a184 integration: add ShouldRetryShutdown case based on #7496
Since the moby/moby can't handle duplicate exit event well, it's hard
for containerd to retry shutdown if there is error, like context
canceled.

In order to prevent from regression like #4769, I add skipped
integration case as TODO item and we should rethink about how to handle
the task/shim lifecycle.

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-11 17:43:51 +08:00
Wei Fu
8dcb2a6e6d pkg/cri/sbserver: fix leaked shim issue for podsandbox mode
Fixes: #7496 #8931

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-11 17:43:51 +08:00
Wei Fu
72bc63d83d pkg/cri/server: fix leaked shim issue
Fixes: #7496 #8931

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-11 17:43:51 +08:00
Wei Fu
5bdd9ca938 integration: add case to reproduce #7496
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-11 17:41:04 +08:00
rongfu.leng
b451fa96a6 bump client-go v0.26.4
Signed-off-by: rongfu.leng <rongfu.leng@daocloud.io>
2023-08-11 00:30:03 +08:00
Akihiro Suda
70a2c95ae8
Merge pull request #8940 from kiashok/updateShimTag-main
Update hcsshim tag to v0.10.0
2023-08-10 10:38:25 +09:00
Kirtana Ashok
a645ff2e68 Update dependencies after protobuf update in hcsshim
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
(cherry picked from commit d129b6f890bceb56b050bbb23ad330bb5699f78c)
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2023-08-09 11:56:45 -07:00
Kirtana Ashok
e7e5619fed Update hcsshim tag to v0.10.0
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2023-08-09 11:55:54 -07:00
rongfu.leng
54baf766e5 add metrics for discarding events
Signed-off-by: rongfu.leng <rongfu.leng@daocloud.io>
2023-08-09 09:56:26 +08:00
root
189a1599c0 archive/compression: update out of date RFC draft link
Signed-off-by: William Chen <willchen.005@gmail.com>
2023-08-08 13:08:02 -07:00
Enrico Weigelt, metux IT consult
cac8b6f4bd Makefile: allow overriding the binary executable target dir
Distros tend to change this to specific locations (eg. on MVCC installs),
therefore introduce a generic environment variable that's a common practise
since 30+ years and thus already well known and supported by distros.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2023-08-08 14:11:03 +02:00
Akihiro Suda
90443f038d
CI: update Rocky Linux to 8.8
- UEFI now has to be enabled
- The root device is now `/dev/mapper/rocky-root`

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-08-08 18:58:24 +09:00