Commit Graph
12537 Commits
Author SHA1 Message Date
Kazuyoshi Kato 6a99fcc88c Merge pull request #10102 from catap/prevent-zero-timer-1.7
[release/1.7] Prevent GC from schedule itself with 0 period.
2024-04-22 10:02:39 -07:00
Kirill A. Korinsky 5c15bf406d Prevent GC from schedule itself with 0 period.
On startup `gcTimeSum` might work fast and return `0`, so on this case
the algorithm turns in infinity loop which simple consume CPU on timer
which fires without any interval.

Use `5ms` as fallback to have interval `245ms` for that case.

Closes: https://github.com/containerd/containerd/issues/5089

Signed-off-by: Kirill A. Korinsky <kirill@korins.ky>
2024-04-22 17:36:25 +02:00
Derek McGowan c37fe74c7d Merge pull request #9865 from kinvolk/rata/userns-update-podSandboxStatus-1.7
[release/1.7]  Include userns info in cri/server PodSandboxStatus
2024-04-22 08:22:31 -07:00
Samuel Karp 22572e2469 Merge pull request #10097 from samuelkarp/bump-nri-v0.6.1-release-1.7
[release/1.7] mod: bump github.com/containerd/nri@v0.6.1
2024-04-19 16:01:42 -07:00
Samuel Karp 395a319015 mod: bump github.com/containerd/nri@v0.6.1
Fixes https://github.com/containerd/containerd/issues/10085

Signed-off-by: Samuel Karp <samuelkarp@google.com>
(cherry picked from commit a153b2cd32)
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2024-04-18 16:18:15 -07:00
Kazuyoshi Kato 03ef4b5ca2 Merge pull request #10065 from sctb512/cherry-pick-9274-to-1.7
[release/1.7] fix bug that using invalid token to retry fetching layer
2024-04-18 16:10:06 -07:00
Kazuyoshi Kato 716d4a23b8 Merge pull request #10077 from elezar/release-1.7-bump-container-device-interface-v0.7.1
[release/1.7] Bump tags.cncf.io/container-device-interface to v0.7.2
2024-04-18 16:08:34 -07:00
Evan Lezar 7a2f49f70f Bump tags.cncf.io/container-device-interface to v0.7.2
This includes migrating from cdi.GetRegistry() to cdi.Configure() and
using top-level cdi Refresh and InjectDevices functions as applicable.

Signed-off-by: Evan Lezar <elezar@nvidia.com>
2024-04-18 16:42:04 +02:00
Samuel Karp 6b0cae9e7c Merge pull request #10071 from anmaxvl/hostProcess-working-dir-fix
[release/1.7] backport: fix default working directory `hostProcess`
2024-04-14 00:54:05 -07:00
Maksim An 989f1ec54f fix default working directory hostProcess
Per https://github.com/kubernetes/enhancements/tree/master/keps/sig-windows/1981-windows-privileged-container-support#container-mounts
the default working directory for `hostProcess` containers should
be `C:\hpc`, however the current default is set to windows default
which is `C:\`.

Signed-off-by: Maksim An <maksiman@microsoft.com>
(cherry picked from commit c7ea06a69b)
2024-04-12 13:34:37 -07:00
Phil Estes fc4b00de18 Merge pull request #10063 from sctb512/cherry-pick-10021-to-1.7
[release/1.7] fix(cri): fix unexpected order of mounts since go 1.19
2024-04-12 14:21:31 -04:00
Maksym Pavlenko 70cf68b82c Merge pull request #9989 from hinshun/backport/1.7-pr9864
[release/1.7] Automatically decompress archives for transfer service import
2024-04-11 10:26:47 -07:00
Bin Tang 9f774e438b fix(cri): fix unexpected order of mounts since go 1.19
Signed-off-by: Bin Tang <tangbin.bin@bytedance.com>
2024-04-11 14:22:18 +08:00
沈陵 f61de08644 fix bug that using invalid token to retry fetching layer
Signed-off-by: frankyang <yyb196@gmail.com>
2024-04-11 14:19:18 +08:00
Fu Wei 088acb03a9 Merge pull request #10056 from kiashok/ctrIntrgeation-backport
[release/1.7] Use different containerd sock address in tests
2024-04-11 14:14:05 +08:00
Kirtana Ashok 8c76e79482 Use different containerd sock address in tests
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
(cherry picked from commit 5b6ae0f796)
Signed-off-by: Kirtana Ashok <kiashok@microsoft.com>
2024-04-09 20:26:35 -07:00
Maksym Pavlenko 3d3287d7ee Merge pull request #10044 from ktock/fail-plain-http-1.7
[release/1.7] remote: Fix HTTPFallback fails when pushing manifest
2024-04-08 16:02:29 -07:00
Phil Estes 6e2411fd8a Merge pull request #9992 from vvoland/vrelease/1.7-8970
[release 1.7] Add support for configuring otel from env and config deprecation notice
2024-04-08 13:11:11 -04:00
Kohei Tokunaga 18f4ad5ee0 remote: Fix HTTPFallback fails when pushing manifest
Signed-off-by: Kohei Tokunaga <ktokunaga.mail@gmail.com>
2024-04-08 15:40:54 +09:00
Maksym Pavlenko 2e4d2e1905 Merge pull request #10042 from dcantah/liststats-1.7
[release/1.7] Add IsNotFound case to ListPodSandboxStats
2024-04-06 20:34:22 -07:00
Danny Canter 90c309fe2f Add IsNotFound case to ListPodSandboxStats
Fixes #10013. It seems we can end up in a spot where the sandbox store still
has a listing for a pod, whereas containerds underlying store has removed it.
It might be better to shield the caller (k8s) from these transient errors.

Signed-off-by: Danny Canter <danny@dcantah.dev>
(cherry picked from commit 2474a99c30)
Signed-off-by: Danny Canter <danny@dcantah.dev>
2024-04-05 11:35:53 -07:00
Derek McGowan 926c9586fe Merge pull request #10039 from estesp/prep-1.7.15
[release/1.7] Prepare for v1.7.15 release
v1.7.15
2024-04-05 10:01:42 -07:00
Phil Estes 4d4759b54d Prep v1.7.15 release
Signed-off-by: Phil Estes <estesp@amazon.com>
2024-04-05 12:06:57 -04:00
Derek McGowan 52fc8ab4d4 Merge pull request #10037 from laurazard/backport-1.7-exec-fix
[release/1.7] Fix runc shim to only defer init process exits
2024-04-05 07:54:59 -07:00
Laura Brehm 21df467662 runc-shim: only defer init process exits
In order to make sure that we don't publish task exit events for init
processes before we do for execs in that container, we added logic to
`processExits` in 892dc54bd2 to skip these
and let the pending exec's `handleStarted` closure process them.

However, the conditional logic in `processExits` added was faulty - we
should only defer processing of exit events related to init processes,
not other execs. Due to this missing condition,
892dc54bd2 introduced a bug where, if
there are many concurrent execs for the same container/init pid, exec
exits are skipped and then never published, resulting in hanging
clients.

This commit adds the missing logic to `processExits`.

Signed-off-by: Laura Brehm <laurabrehm@hey.com>
(cherry picked from commit 6d00c3ada8)
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
2024-04-05 14:36:24 +01:00
Phil Estes 0dcf21c152 Merge pull request #10012 from austinvazquez/release-1.7-fix-offline-compilation
[release/1.7] Fix compile from version control system (source) use case
2024-03-29 15:34:53 -04:00
Austin Vazquez 2a054213e7 Fix compile from version control system (source) use case
This change excludes the github.com/mitchellh/osext indirect dependency
to resolve compile from source use case issue due to dependency no
longer being available.

Signed-off-by: Austin Vazquez <macedonv@amazon.com>
2024-03-28 04:14:39 +00:00
Phil Estes ec5222f2a6 Merge pull request #9990 from daghack/oci-add-mediatype-1.7
[release/1.7] adds mediatype to oci index record
2024-03-26 21:39:18 -04:00
Paweł Gronowski 600ba86122 vendor: revendor OTEL
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2024-03-25 17:38:08 +01:00
Brian Goff 9360e37169 Changes to configuring otel from env only
These are standard environment variables described by the otel spec in
https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/.

The old config options are removed

Also since otel will by default try to connect to https://localhost:4318
if no endpoint is set, this will also just disable the otlp plugin when
there is no endpoint so we don't have otel continuously trying to
connect to the default endpoint, littering the logs with connection
failure messages and collecting traces that won't go anywhere.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 4fbc9842d5)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2024-03-25 17:30:16 +01:00
Brian Goff f2354894f3 Deprecate otel configs
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 753a525b3b)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2024-03-25 17:04:24 +01:00
Talon 6605c47a41 adds mediatype to oci index record
Signed-off-by: Talon Bowler <talon.bowler@docker.com>
(cherry picked from commit 17ea3959bc)
2024-03-25 07:59:17 -07:00
Edgar Lee 2aec52493f Automatically decompress archives for transfer service import
Signed-off-by: Edgar Lee <edgarhinshunlee@gmail.com>
2024-03-24 02:17:19 +08:00
Derek McGowan be5ec973f5 Merge pull request #9975 from thaJeztah/1.7_bump_protobuf
[release/1.7 backport] vendor: google.golang.org/protobuf 1.33.0, github.com/golang/protobuf v1.5.4
2024-03-22 15:32:12 -07:00
Sebastiaan van Stijn e6d91d843f vendor: github.com/golang/protobuf v1.5.4
commit 10c7f03b3b updated google.golang.org/protobuf
to v1.33.0, which addresses CVE-2024-24786, however a follow-up post on the
Golang security list issued a warning that the v1.33.0 update introduced a
breaking change, causing compatibility with github.com/golang/protobuf to be
broken;

> A small correction: This vulnerability applies when the UnmarshalOptions.DiscardUnknown
> option is set (as well as when unmarshaling into any message which contains a
> google.protobuf.Any). There is no UnmarshalUnknown option.
>
> In addition, version 1.33.0 of google.golang.org/protobuf inadvertently
> introduced an incompatibility with the older github.com/golang/protobuf
> module. (https://github.com/golang/protobuf/issues/1596) Users of the older
> module should update to github.com/golang/protobuf@v1.5.4.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 45e425ccce)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-03-20 10:25:31 +01:00
dependabot[bot] 2d136c5f5e build(deps): bump google.golang.org/protobuf from 1.32.0 to 1.33.0
Bumps google.golang.org/protobuf from 1.32.0 to 1.33.0.

---
updated-dependencies:
- dependency-name: google.golang.org/protobuf
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 10c7f03b3b)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-03-20 10:24:23 +01:00
dependabot[bot] a1a7af7a39 build(deps): bump google.golang.org/protobuf from 1.31.0 to 1.32.0
Bumps google.golang.org/protobuf from 1.31.0 to 1.32.0.

---
updated-dependencies:
- dependency-name: google.golang.org/protobuf
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 7fe038e4a5)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-03-20 10:22:18 +01:00
Derek McGowan dcf2847247 Merge pull request #9953 from dmcgowan/prepare-v1.7.14
[release/1.7] Prepare release notes for v1.7.14
v1.7.14
2024-03-11 08:10:24 -07:00
Derek McGowan 1babe6b582 Prepare release notes for v1.7.14
Signed-off-by: Derek McGowan <derek@mcg.dev>
2024-03-08 11:59:11 -08:00
Maksym Pavlenko 9138da4120 Merge pull request #9951 from austinvazquez/release-1.7-backport-use-matrix-go-version
[release/1.7] Backport use Go toolchain in CI matrix to build binaries
2024-03-08 10:18:51 -08:00
Austin Vazquez a9bbbefcf2 Use the Go toolchain in CI matrix to build binaries
Signed-off-by: Austin Vazquez <macedonv@amazon.com>
(cherry picked from commit 7ac9d6909c)
Signed-off-by: Austin Vazquez <macedonv@amazon.com>
2024-03-08 15:26:02 +00:00
Akihiro Suda 17cbd50331 Merge pull request #9933 from AkihiroSuda/go-1.21.8-1.7
[release/1.7] update to go 1.21.8, 1.22.1
2024-03-08 08:31:37 +09:00
Maksym Pavlenko 4c825b3743 Merge pull request #9938 from akhilerm/cherry-pick-9777-1.7
[release/1.7] Move inline PS scripts into files
2024-03-07 08:57:10 -08:00
Maksym Pavlenko 39caf532e7 Move inline PS scripts into files
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
(cherry picked from commit 32bd8eff9e)
Signed-off-by: Akhil Mohan <akhilerm@gmail.com>
2024-03-07 16:25:17 +05:30
Akihiro Suda 5613faeb7f Merge pull request #9944 from dmcgowan/1.7-skip-oom-test
[release/1.7] Disable OOM set score unpriv test temporarily
2024-03-07 17:33:08 +09:00
Akihiro Suda 1ca9a643a1 update to go 1.21.8, 1.22.1
See https://groups.google.com/g/golang-announce/c/5pwGVUPoMbg

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
(cherry picked from commit 670339d59ce8afd35f53841d78d8a611e4a177c2)
> Conflicts:
>	.github/workflows/ci.yml
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2024-03-07 17:32:14 +09:00
Phil Estes 630226bb43 Disable OOM set score unpriv test temporarily
Temporary skip while we find root cause of GHA environment changes
causing failure.

Signed-off-by: Phil Estes <estesp@amazon.com>
(cherry picked from commit 723306d0ed)
Signed-off-by: Derek McGowan <derek@mcg.dev>
2024-03-06 21:56:41 -08:00
Derek McGowan 69ca1b2871 Merge pull request #9928 from laurazard/1.7-backport-exec-exit-order
[release/1.7] runc-shim: process exec exits before init
2024-03-05 12:17:13 -08:00
Laura Brehm de7b6bae9e runc-shim: process exec exits before init
For a given container, as long as the init process is the init process
of that PID namespace, we always receive the exits for execs before we
receive them for the init process.

It's important that we uphold this invariant for the outside world by
always emitting a TastExit event for a container's exec before we emit
one for the init process because this is the expected behavior from
callers, and changing this creates issues - such as Docker, which will
delete the container after receiving a TaskExit for the init process,
and then not be able to handle the exec's exit after having deleted
the container (see: https://github.com/containerd/containerd/issues/9719).

Since 5cd6210ad0, if an exec is starting
at the same time that an init exits, if the exec is an "early exit"
i.e. we haven't emitted a TaskStart for it/put it in `s.running` by the
time we receive it's exit, we notify concurrent calls to `s.Start()` of
the exit and continue processing exits, which will cause us to process
the Init's exit before the exec, and emit it, which we don't want to do.

This commit introduces a map `s.pendingExecs` to keep track of the
number of pending execs keyed by container, which allows us to skip
processing exits for inits if there are pending execs, and instead
have the closure returned by `s.preStart` handle the init exit after
emitting the exec's exit.

Signed-off-by: Laura Brehm <laurabrehm@hey.com>
(cherry picked from commit 892dc54bd2)
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
2024-03-05 03:16:24 +00:00
Akihiro Suda 92b1d4e1e8 Merge pull request #9860 from akhilerm/update-go-version-1.7
[release/1.7] update to go 1.21.6, test 1.22.0
2024-03-05 10:52:18 +09:00