summaryrefslogtreecommitdiff
path: root/libpod/container_internal.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-12-17 16:04:26 +0100
committerGitHub <noreply@github.com>2021-12-17 16:04:26 +0100
commit59766ebe76fe5bdd15256f5d39d063c95304989f (patch)
tree97e92d5a1ce224481b78003dd8ef6f65a913cf1c /libpod/container_internal.go
parent820cf0e0661764de4e61e3d27a603acec817a363 (diff)
parent28018ce604057633cf88fc34719ce28a812237b3 (diff)
downloadpodman-59766ebe76fe5bdd15256f5d39d063c95304989f.tar.gz
podman-59766ebe76fe5bdd15256f5d39d063c95304989f.tar.bz2
podman-59766ebe76fe5bdd15256f5d39d063c95304989f.zip
Merge pull request #12625 from adrianreber/2021-12-16-podman-inspect
Add more checkpoint/restore information to 'inspect'
Diffstat (limited to 'libpod/container_internal.go')
-rw-r--r--libpod/container_internal.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/libpod/container_internal.go b/libpod/container_internal.go
index 7df82eb18..7ae9daefa 100644
--- a/libpod/container_internal.go
+++ b/libpod/container_internal.go
@@ -634,6 +634,12 @@ func resetState(state *ContainerState) {
state.RestartPolicyMatch = false
state.RestartCount = 0
state.Checkpointed = false
+ state.Restored = false
+ state.CheckpointedTime = time.Time{}
+ state.RestoredTime = time.Time{}
+ state.CheckpointPath = ""
+ state.CheckpointLog = ""
+ state.RestoreLog = ""
}
// Refresh refreshes the container's state after a restart.
@@ -1111,6 +1117,12 @@ func (c *Container) init(ctx context.Context, retainRetries bool) error {
}
c.state.Checkpointed = false
+ c.state.Restored = false
+ c.state.CheckpointedTime = time.Time{}
+ c.state.RestoredTime = time.Time{}
+ c.state.CheckpointPath = ""
+ c.state.CheckpointLog = ""
+ c.state.RestoreLog = ""
c.state.ExitCode = 0
c.state.Exited = false
c.state.State = define.ContainerStateCreated