summaryrefslogtreecommitdiff
path: root/libpod/container_internal.go
diff options
context:
space:
mode:
Diffstat (limited to 'libpod/container_internal.go')
-rw-r--r--libpod/container_internal.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/libpod/container_internal.go b/libpod/container_internal.go
index 2f258d007..66d1e44ad 100644
--- a/libpod/container_internal.go
+++ b/libpod/container_internal.go
@@ -329,6 +329,12 @@ func resetState(state *containerState) error {
// Refresh refreshes the container's state after a restart
func (c *Container) refresh() error {
+ // Don't need a full sync, but we do need to update from the database to
+ // pick up potentially-missing container state
+ if err := c.runtime.state.UpdateContainer(c); err != nil {
+ return err
+ }
+
if !c.valid {
return errors.Wrapf(ErrCtrRemoved, "container %s is not valid - may have been removed", c.ID())
}