Wei Fu
4ce334aa49
reload cni network config if has fs change events
...
With go RWMutex design, no goroutine should expect to be able to
acquire a read lock until the read lock has been released, if one
goroutine call lock.
The original design is to reload cni network config on every single
Status CRI gRPC call. If one RunPodSandbox request holds read lock
to allocate IP for too long, all other RunPodSandbox/StopPodSandbox
requests will wait for the RunPodSandbox request to release read lock.
And the Status CRI call will fail and kubelet becomes NOTReady.
Reload cni network config at every single Status CRI call is not
necessary and also brings NOTReady situation. To lower the possibility
of NOTReady, CRI will reload cni network config if there is any valid fs
change events from the cni network config dir.
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2020-04-03 12:28:58 +08:00
Lantao Liu
50c73e6dc5
Move unix specific logic into _unix.go
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2019-09-03 16:23:42 -07:00
Lantao Liu
ba8788c6b9
Update kubernetes dependency to 1.15.0.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2019-07-31 23:52:03 -07:00
Aldo Culquicondor
4b43303203
Add option to register on TCP server
...
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2019-07-25 09:42:49 -04:00
Lantao Liu
322cd48965
Remove load image support
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2019-06-12 11:14:11 -07:00
kuramal
b022de5f37
add cni plugin config file max num config, set go-cni to commit 22460c0
...
Signed-off-by: kuramal <linxxnil@126.com>
2019-06-10 12:14:35 +08:00
Lantao Liu
8222da7768
Support stream idle timeout.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2019-02-28 01:30:01 -08:00
Akihiro Suda
cd8231ab2a
support DisableCgroup, DisableApparmor, RestrictOOMScoreAdj
...
Add following config for supporting "rootless" mode
* DisableCgroup: disable cgroup
* DisableApparmor: disable Apparmor
* RestrictOOMScoreAdj: restrict the lower bound of OOMScoreAdj
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
2019-01-03 05:12:04 +09:00
Lantao Liu
db68300a5a
Manage unmanaged images in k8s.io namespace
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-09-27 11:19:11 -07:00
Lantao Liu
953d67d250
Create image reference cache.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-09-10 11:30:52 -07:00
Lantao Liu
4eb4a29577
Merge pull request #825 from abhi/cni_config
...
Change to keep in sync with latest cni config
2018-06-21 16:14:31 -07:00
Abhinandan Prativadi
263b0b99d0
Change to keep in sync with latest cni config
...
This commit contains change to pick the latest cni config
from the configured CNIConfDir.
With this change any changes made to the cni config file will
be picked up on the kubelet's runtime status check call.
Ofcourse this would lead to undefined behavior when the cni config
change is made in parallel during pod creation. However its
reasonable to assume that the operator is aware of the need to
drain the nodes of pods before making cni configuration change.
The behavior is currently not defined in kubernetes. However
I see that similar approach being adopted in the upstream kubernetes
with dockershim. Keeping the behavior consistent for now.
Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
2018-06-21 20:43:38 +00:00
Lantao Liu
b60e456bd9
Fix snapshotter nil panic.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-06-20 00:43:44 +00:00
Lantao Liu
b870ee7942
Generate fatal error when cri plugin fail to start.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-05-31 10:49:11 -07:00
Lantao Liu
387da59ee5
Rename all variables to remove "cricontainerd".
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-03-19 21:59:32 +00:00
Lantao Liu
e1fe1abff0
Use github.com/pkg/errors
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-03-17 02:24:38 +00:00
abhi
003bbd4292
Modifying fake cni plugin
...
Signed-off-by: abhi <abhi@docker.com>
2018-03-15 17:05:33 -07:00
abhi
92110e1d74
Moving to use go-cni library from containerd
...
This fix aims to use the cni library form containerd.
The library avoid usage of nsenter.
Signed-off-by: abhi <abhi@docker.com>
2018-03-14 19:25:54 -07:00
Mike Brown
d4e7154625
move links for cri-containerd to cri
...
Signed-off-by: Mike Brown <brownwm@us.ibm.com>
2018-03-13 17:06:26 -05:00
Lantao Liu
f0a500a390
Use direct function call.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-03-13 04:51:19 +00:00
Lantao Liu
d1e9960180
Remove standalone mode
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-03-05 21:45:20 +00:00
Lantao Liu
6d538ccbf6
Do not block on stream server close.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-02-14 08:41:29 +00:00
Lantao Liu
6900cbdada
Use mountpoint as image fs identifier.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-02-09 07:46:49 +00:00
Lantao Liu
605b4a7b6a
Update imports
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-02-08 02:45:44 +00:00
Lantao Liu
e7f2a74a84
Add runtime cgroup and fix a cli panic.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-25 22:32:57 +00:00
Lantao Liu
635e5747c0
Update containerd and leverage plugin graceful stop.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-23 22:46:46 +00:00
Lantao Liu
4e9ca399e1
Use containerd plugin config.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-19 02:25:03 +00:00
Lantao Liu
7d18d61674
Move cgroup and oom score setting to cmd.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-19 01:35:36 +00:00
Lantao Liu
62e6921145
Use containerd grpc server
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-18 18:51:18 +00:00
Lantao Liu
3d68005c04
Replace glog with logrus
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-17 21:57:31 +00:00
Lantao Liu
025ffe551f
Rename kubernetes-incubator/cri-containerd to containerd/cri-containerd.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-10 22:35:33 +00:00
Lantao Liu
dca05358dc
Add flag to skip imagefs uuid related logic.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-01-08 18:41:13 +00:00
yason
4762b3e273
remove taskService and imageStoreService
...
Signed-off-by: yason <yan.xuean@zte.com.cn>
2017-12-12 16:51:22 +08:00
yason
41c8763e2b
improve calling for content
...
Signed-off-by: yason <yan.xuean@zte.com.cn>
2017-12-11 15:28:10 +08:00
Lantao Liu
25fdf72692
Add image load.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-10-27 21:51:04 +00:00
yanxuean
3887b0a1a0
Add a flag to set OOMScore
...
fix #337
Signed-off-by: yanxuean <yan.xuean@zte.com.cn>
2017-10-12 16:43:35 +08:00
Lantao Liu
6cb3d27ed3
Use device number to find uuid
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-10-09 06:10:43 +00:00
Lantao Liu
517f697f62
Better format several errors
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-28 01:15:06 +00:00
Mike Brown
d8a3c6b018
adds support for configuring the containerd runtime engine
...
Signed-off-by: Mike Brown <brownwm@us.ibm.com>
2017-09-26 20:22:51 -05:00
Lantao Liu
4231473df3
Address comments
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-25 23:09:44 +00:00
Lantao Liu
491400c892
Add ImageFsInfo support
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-25 21:02:29 +00:00
Lantao Liu
cc1b0b6709
Add restart recovery logic.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-21 17:59:46 +00:00
Lantao Liu
71b0d0a043
Use config in service.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-17 06:46:40 +00:00
Lantao Liu
b074388460
Update containerd to v1.0.0-beta.0
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-09 04:46:02 +00:00
Lantao Liu
7a75a91578
Merge pull request #225 from Random-Liu/update-ocicni
...
Update ocicni to 73f1309d6bc5c3eac78c1382408921cd771ff22e
2017-09-06 21:04:45 -07:00
Lantao Liu
f36ef46b35
Use new ocicni.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-07 00:14:12 +00:00
Lantao Liu
2b6302d91d
Remove an addressed TODO.
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-06 23:29:27 +00:00
Jamie Zhuang
915f5b0aea
Make sandbox container image configurable
...
Signed-off-by: Jamie Zhuang <lanchongyizu@gmail.com>
2017-09-03 02:53:17 -04:00
Lantao Liu
c3e8c69aff
Let cri-containerd exit with containerd
...
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-01 23:14:04 +00:00
Abhinandan Prativadi
e1edeae4c9
Adding option to configure cgroup to start cri-containerd
...
Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
2017-08-30 14:37:40 -07:00