diff options
author | 3sky <3sky@protonmail.com> | 2020-10-09 16:57:07 +0200 |
---|---|---|
committer | 3sky <3sky@protonmail.com> | 2020-10-12 08:51:47 +0200 |
commit | 1fc64c8a5acdabfc08da29d45109085c3135df30 (patch) | |
tree | cc97fe09ebcd9f0301eb8bbd2c6282ae558f3580 | |
parent | 2587cba3899213356575f01cc0aa226c0209b8ae (diff) | |
download | podman-1fc64c8a5acdabfc08da29d45109085c3135df30.tar.gz podman-1fc64c8a5acdabfc08da29d45109085c3135df30.tar.bz2 podman-1fc64c8a5acdabfc08da29d45109085c3135df30.zip |
Resolve #7860 - add time.RFC3339Nano into ContainerJSONBase
Signed-off-by: 3sky <3sky@protonmail.com>
-rw-r--r-- | pkg/api/handlers/compat/containers.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/api/handlers/compat/containers.go b/pkg/api/handlers/compat/containers.go index 48ecfff5d..cae8f88fd 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, |