From f9bad6cc32e9a69723512ad986d5767b520d622d Mon Sep 17 00:00:00 2001 From: Samuel Ortiz Date: Wed, 27 Sep 2017 12:06:13 +0200 Subject: [PATCH] oci: Use error logs for container creation failures They are more critical than simple debug strings. Signed-off-by: Samuel Ortiz --- oci/oci.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/oci/oci.go b/oci/oci.go index e9babb7f..a8584783 100644 --- a/oci/oci.go +++ b/oci/oci.go @@ -271,13 +271,14 @@ func (r *Runtime) CreateContainer(c *Container, cgroupParent string) error { logrus.Debugf("Received container pid: %d", ss.si.Pid) if ss.si.Pid == -1 { if ss.si.Message != "" { - logrus.Debugf("Container creation error: %s", ss.si.Message) + logrus.Errorf("Container creation error: %s", ss.si.Message) return fmt.Errorf("container create failed: %s", ss.si.Message) } - logrus.Debugf("Container creation failed") + logrus.Errorf("Container creation failed") return fmt.Errorf("container create failed") } case <-time.After(ContainerCreateTimeout): + logrus.Errorf("Container creation timeout (%v)", ContainerCreateTimeout) return fmt.Errorf("create container timeout") } return nil