From 4e6e1cab0d3825c628c2936cf9bbe76510c35ad6 Mon Sep 17 00:00:00 2001 From: Lantao Liu Date: Mon, 30 Oct 2017 05:57:13 +0000 Subject: [PATCH] Add the missing container log path in container status. Signed-off-by: Lantao Liu --- pkg/server/container_status.go | 1 + pkg/server/container_status_test.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/pkg/server/container_status.go b/pkg/server/container_status.go index 45950ed95..cb5728465 100644 --- a/pkg/server/container_status.go +++ b/pkg/server/container_status.go @@ -74,5 +74,6 @@ func toCRIContainerStatus(container containerstore.Container, imageRef string) * Labels: meta.Config.GetLabels(), Annotations: meta.Config.GetAnnotations(), Mounts: meta.Config.GetMounts(), + LogPath: meta.LogPath, } } diff --git a/pkg/server/container_status_test.go b/pkg/server/container_status_test.go index 51e2e5fb6..c25ae2a9a 100644 --- a/pkg/server/container_status_test.go +++ b/pkg/server/container_status_test.go @@ -54,6 +54,7 @@ func getContainerStatusTestData() (*containerstore.Metadata, *containerstore.Sta SandboxID: "test-sandbox-id", Config: config, ImageRef: "test-image-id", + LogPath: "test-log-path", } status := &containerstore.Status{ Pid: 1234, @@ -76,6 +77,7 @@ func getContainerStatusTestData() (*containerstore.Metadata, *containerstore.Sta Labels: config.GetLabels(), Annotations: config.GetAnnotations(), Mounts: config.GetMounts(), + LogPath: "test-log-path", } return metadata, status, image, expected