Wei Fu
6b7e237fc7
chore: use go fix to cleanup old +build buildtag
...
Signed-off-by: Wei Fu <fuweid89@gmail.com >
2022-12-29 14:25:14 +08:00
Derek McGowan
27f43506b4
Merge pull request #7872 from yanggangtony/cri-sbserver
...
CRI sbserver: Prevent server reuse after Shutdown
2022-12-27 15:54:29 -08:00
yanggang
e94d925711
CRI sbserver: Prevent server reuse after Shutdown.
...
Signed-off-by: yanggang <gang.yang@daocloud.io >
2022-12-27 14:16:40 +08:00
Danny Canter
229779a4e5
oci: Add WithDomainname
...
A domainname field was recently added to the OCI spec. Prior to this
folks would need to set this with a sysctl, but now runtimes should be
able to setdomainname(2). There's an open change to runc at the moment
to add support for this so I've just left testing as a couple spec
validations in CRI until that's in and usable.
Signed-off-by: Danny Canter <danny@dcantah.dev >
2022-12-26 04:03:45 -05:00
Fu Wei
4c3eb5f0c3
Merge pull request #7858 from aojea/network_metrics
2022-12-26 09:03:16 +08:00
Kazuyoshi Kato
84b81a89ff
Merge pull request #7859 from dmcgowan/unpacker-warn-remove
...
Avoid using canceled context in unpacker cleanup
2022-12-23 08:11:53 -08:00
Antonio Ojea
ba0a7185f0
add network plugin metrics
...
Add network plugin metrics.
The metrics are the same that were used in dockershim/kubelet until
it was deprecated in kubernetes 1.23
https://github.com/kubernetes/kubernetes/blob/release-1.23/pkg/kubelet/dockershim/network/metrics/metrics.go
Signed-off-by: Antonio Ojea <aojea@google.com >
2022-12-23 09:23:56 +00:00
Derek McGowan
0bc9f7b545
Avoid using canceled context in unpacker cleanup
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-12-22 14:53:23 -08:00
Derek McGowan
b3b79813f3
Merge pull request #7165 from zouyee/nit
...
prevent Server reuse after a Shutdown
2022-12-22 14:09:29 -08:00
Danny Canter
3ee6dd5c1b
CRI: Fix no CNI info for pod sandbox on restart
...
Due to when we were updating the pod sandboxes underlying container
object, the pointer to the sandbox would have the right info, but
the on-disk representation of the data was behind. This would cause
the data returned from loading any sandboxes after a restart to have
no CNI result or IP information for the pod.
This change does an additional update to the on-disk container info
right after we invoke the CNI plugin so the metadata for the CNI result
and other networking information is properly flushed to disk.
Signed-off-by: Danny Canter <danny@dcantah.dev >
2022-12-20 13:20:27 -08:00
Akihiro Suda
4157503881
cri: fix memory.memsw.limit_in_bytes: no such file or directory
...
Skip automatic `if swapLimit == 0 { s.Linux.Resources.Memory.Swap = &limit }` when the swap controller is missing.
(default on Ubuntu 20.04)
Fix issue 7828 (regression in PR 7783 "cri: make swapping disabled with memory limit")
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp >
2022-12-19 11:28:07 +09:00
Kazuyoshi Kato
52a7480399
Remove github.com/gogo/protobuf again
...
While we need to support CRI v1alpha2, the implementation doesn't have
to be tied to gogo/protobuf.
Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com >
2022-12-15 22:54:15 +00:00
Derek McGowan
a4bc380b91
Merge pull request #7814 from dcantah/hostnet-helper
...
CRI: Add host networking helper
2022-12-15 11:21:45 -08:00
Fu Wei
12f30e6524
Merge pull request #7792 from mxpv/sb-shutdown
2022-12-15 13:37:35 +08:00
Maksym Pavlenko
a4d5c3e5cb
Support sandboxed shims shutdown
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-14 18:22:52 -08:00
Phil Estes
9b39b0bfd9
Merge pull request #7812 from mxpv/cri
...
Minor fix when querying pod sandbox status
2022-12-14 10:15:03 -05:00
Danny Canter
84529072d2
CRI: Add host networking helper
...
We do a ton of host networking checks around the CRI plugin, all mainly
doing the same thing of checking the different quirks on various platforms
(for windows are we a HostProcess pod, for linux is namespace mode the
right thing, darwin doesn't have CNI support etc.) which could all be
bundled up into a small helper that can be re-used.
Signed-off-by: Danny Canter <danny@dcantah.dev >
2022-12-14 01:47:22 -08:00
Maksym Pavlenko
371e27ffb2
Merge pull request #7809 from mikebrow/check-deep-copies-on-restart
...
nil check to avoid panic on upgrade
2022-12-13 22:22:20 -08:00
Maksym Pavlenko
0e33a8fa4f
[sb] Fix status
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-13 16:35:15 -08:00
Derek McGowan
c666147592
Merge pull request #7805 from chaunceyjiang/painc
...
fatal error: concurrent map iteration and map write
2022-12-13 15:01:25 -08:00
Mike Brown
ce3a732709
nil check to avoid panic on upgrade
...
Signed-off-by: Mike Brown <brownwm@us.ibm.com >
2022-12-13 16:18:18 -06:00
Phil Estes
ecf00ffe84
Merge pull request #7783 from inspektor-gadget/qasim/cri-disable-swap
...
cri: make swapping disabled with memory limit
2022-12-13 15:21:51 -05:00
chaunceyjiang
5a3a9baec9
fatal error: concurrent map iteration and map write
...
Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com >
2022-12-13 20:08:23 +08:00
Fu Wei
d2f68bfb36
Merge pull request #7313 from pacoxu/image-pull-metrics
...
add metrics for image pulling: error; in progress count; thoughput
2022-12-13 19:49:22 +08:00
Akihiro Suda
dc48349248
epoch: propagate SOURCE_DATE_EPOCH via ctx
...
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp >
2022-12-12 09:02:35 +09:00
Phil Estes
a7428f4473
Merge pull request #7732 from AkihiroSuda/sha256-simd
...
digest: use github.com/minio/sha256-simd
2022-12-09 09:37:37 -05:00
Fu Wei
f2cf411b79
Merge pull request #7073 from ruiwen-zhao/event
...
Add container event support to containerd
2022-12-09 15:24:23 +08:00
Maksym Pavlenko
e1abaeb386
Merge pull request #7764 from mxpv/config
...
Pass TOML configuration options for runtimes CRI is not aware of
2022-12-08 12:59:13 -08:00
ruiwen-zhao
a6929f9f6b
Add Evented PLEG support to sandbox server
...
Signed-off-by: ruiwen-zhao <ruiwen@google.com >
2022-12-08 19:31:36 +00:00
ruiwen-zhao
a338abc902
Add container event support to containerd
...
Signed-off-by: ruiwen-zhao <ruiwen@google.com >
2022-12-08 19:30:39 +00:00
Maksym Pavlenko
3bc8fc4d30
Cleanup build constraints
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-08 09:36:20 -08:00
Qasim Sarfraz
69975b92bb
cri: make swapping disabled with memory limit
...
OCI runtime spec defines memory.swap as 'limit of memory+Swap usage'
so setting them to equal should disable the swap. Also, this change
should make containerd behaviour same as other runtimes e.g
'cri-dockerd/dockershim' and won't be impacted when user turn on
'NodeSwap' (https://github.com/kubernetes/enhancements/issues/2400 ) feature.
Signed-off-by: Qasim Sarfraz <qasimsarfraz@microsoft.com >
2022-12-08 13:54:55 +01:00
Akihiro Suda
cde9490779
digest: use github.com/minio/sha256-simd
...
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp >
2022-12-08 18:50:00 +09:00
Maksym Pavlenko
d10dbd2d2d
Merge pull request #7773 from mxpv/ctx
...
Fix context when waiting sandbox
2022-12-07 13:53:37 -08:00
Derek McGowan
241563be06
Merge pull request from GHSA-2qjp-425j-52j9
...
CRI stream server: Fix goroutine leak in Exec
2022-12-07 13:50:26 -08:00
Maksym Pavlenko
f9295aa49f
Fix context when waiting sandbox
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-07 12:52:04 -08:00
Maksym Pavlenko
8ab1d44967
Pass runtime configuration as TOML blob
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-07 10:55:06 -08:00
Maksym Pavlenko
3e92dedc2e
Update runtime options to include bytes blob
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-07 10:55:06 -08:00
Paco Xu
c59f1635f0
add metrics for image pulling: success/failure count; in progress count; thoughput
...
Signed-off-by: Paco Xu <paco.xu@daocloud.io >
2022-12-07 15:11:00 +08:00
Maksym Pavlenko
03a4dc0711
Merge pull request #7768 from mxpv/fixes
...
sbserver bug fixing
2022-12-06 17:07:54 -08:00
Maksym Pavlenko
a113737ccf
sbserver bug fixing
...
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com >
2022-12-06 15:32:42 -08:00
Phil Estes
5d4276cc34
Merge pull request #7525 from thaJeztah/remove_deprecated_stubs
...
remove some (aliases for) deprecated functions
2022-12-06 11:49:18 -05:00
Derek McGowan
8a25fa584f
Unwrap proto errors in streaming client
...
Allows clients to properly detect context cancellation
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-12-02 22:30:54 -08:00
Derek McGowan
51195ad099
Merge pull request #7731 from mxpv/cri
...
[Sandbox API] CRI status cleanup
2022-12-01 13:43:13 -08:00
Derek McGowan
f88162587b
Rename transferer to transferrer
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 16:02:09 -08:00
Derek McGowan
fc2754204f
Cleanup code comments and lint fixes
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 16:02:09 -08:00
Derek McGowan
c387a52051
Add variables names to transfer interface
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 12:56:57 -08:00
Derek McGowan
8304a61b53
Combine stream fuzz tests
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 12:56:57 -08:00
Derek McGowan
0762a3a759
Add media type to export stream
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 12:56:57 -08:00
Derek McGowan
11c1c8e6f4
Update import logic
...
Signed-off-by: Derek McGowan <derek@mcg.dev >
2022-11-30 12:56:56 -08:00