diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-10-06 20:09:04 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-06 20:09:04 +0200 |
commit | 470e52f272a4a8541e867fb2c6477e722175066c (patch) | |
tree | dd50e4672729412a0ceb9cd30d83cf7a9726e965 /pkg | |
parent | 03c17e94078236531b02ab437721853a09df119f (diff) | |
parent | 8bd9f58d1d0db76406dca53907095648f4091f9f (diff) | |
download | podman-470e52f272a4a8541e867fb2c6477e722175066c.tar.gz podman-470e52f272a4a8541e867fb2c6477e722175066c.tar.bz2 podman-470e52f272a4a8541e867fb2c6477e722175066c.zip |
Merge pull request #11878 from mheon/stop_stopping
Allow `podman stop` to be run on Stopping containers
Diffstat (limited to 'pkg')
-rw-r--r-- | pkg/ps/ps.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pkg/ps/ps.go b/pkg/ps/ps.go index 69ac9c215..90ad23f49 100644 --- a/pkg/ps/ps.go +++ b/pkg/ps/ps.go @@ -136,6 +136,12 @@ func ListContainerBatch(rt *libpod.Runtime, ctr *libpod.Container, opts entities ) batchErr := ctr.Batch(func(c *libpod.Container) error { + if opts.Sync { + if err := c.Sync(); err != nil { + return errors.Wrapf(err, "unable to update container state from OCI runtime") + } + } + conConfig = c.Config() conState, err = c.State() if err != nil { |