From 43eb1e3707e2f418dae2479ea6bc2c458e1d1936 Mon Sep 17 00:00:00 2001 From: lijianguo Date: Fri, 30 Aug 2024 15:20:58 +0800 Subject: [PATCH] chore(controller): pod failed do not rollback --- rootfs/scheduler/resources/pod.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rootfs/scheduler/resources/pod.py b/rootfs/scheduler/resources/pod.py index b9695c38b..941f1bad6 100644 --- a/rootfs/scheduler/resources/pod.py +++ b/rootfs/scheduler/resources/pod.py @@ -523,6 +523,7 @@ def _handle_pod_errors(self, pod, reason, message): 'ImagePullBackOff', 'RegistryUnavailable', 'ErrImageInspect', + "CreateContainerError", ] # Image event reason mapping event_errors = { @@ -537,7 +538,7 @@ def _handle_pod_errors(self, pod, reason, message): # Nicer error than from the event # Often this gets to ImageBullBackOff before we can introspect tho - if reason == 'ErrImagePull': + if reason in ['ErrImagePull', 'CreateContainerError']: raise KubeException(message) # collect all error messages of worth