From 8e7051d2f551b3ecd485ab7ff97738d8593ee509 Mon Sep 17 00:00:00 2001 From: 3sky <3sky@protonmail.com> Date: Fri, 9 Oct 2020 16:57:07 +0200 Subject: [PATCH] Resolve #7860 - add time.RFC3339Nano into ContainerJSONBase Signed-off-by: 3sky <3sky@protonmail.com> --- pkg/api/handlers/compat/containers.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/api/handlers/compat/containers.go b/pkg/api/handlers/compat/containers.go index 48ecfff5d8..cae8f88fd1 100644 --- a/pkg/api/handlers/compat/containers.go +++ b/pkg/api/handlers/compat/containers.go @@ -7,6 +7,7 @@ import ( "strconv" "strings" "syscall" + "time" "github.com/containers/podman/v2/libpod" "github.com/containers/podman/v2/libpod/define" @@ -316,7 +317,7 @@ func LibpodToContainerJSON(l *libpod.Container, sz bool) (*types.ContainerJSON, cb := types.ContainerJSONBase{ ID: l.ID(), - Created: l.CreatedTime().String(), + Created: l.CreatedTime().Format(time.RFC3339Nano), Path: "", Args: nil, State: &state,