From 62b3395b18b8954c5a37f3463acf90420d854938 Mon Sep 17 00:00:00 2001 From: xulei Date: Wed, 25 Oct 2023 03:42:17 +0000 Subject: [PATCH] Fix the abnormal logic of starting the container time out. Signed-off-by: xulei (cherry picked from commit 8d9abebd652988328c3cc644e339d2ecfae763ee) --- ...ntainerd-set-create-and-exec-timeout-to-avild-bloc.patch | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/patch/0007-containerd-set-create-and-exec-timeout-to-avild-bloc.patch b/patch/0007-containerd-set-create-and-exec-timeout-to-avild-bloc.patch index b07af71..016479f 100644 --- a/patch/0007-containerd-set-create-and-exec-timeout-to-avild-bloc.patch +++ b/patch/0007-containerd-set-create-and-exec-timeout-to-avild-bloc.patch @@ -92,7 +92,7 @@ diff --git a/vendor/github.com/containerd/go-runc/runc.go b/vendor/github.com/co index 0feedeb..15fc8e1 100644 --- a/vendor/github.com/containerd/go-runc/runc.go +++ b/vendor/github.com/containerd/go-runc/runc.go -@@ -54,8 +54,22 @@ const ( +@@ -54,8 +54,20 @@ const ( Text Format = "text" // DefaultCommand is the default command for Runc DefaultCommand = "runc" @@ -105,9 +105,7 @@ index 0feedeb..15fc8e1 100644 + +func init() { + runtimeTimeout, err := convertTime(os.Getenv("DOCKER_RUNTIME_START_TIMEOUT")) -+ if err != nil { -+ logrus.Warnf("init error, wrong runtimeTimeout format: %v", err) -+ } else { ++ if err == nil { + createTimeout = runtimeTimeout + } +} -- Gitee