diff options
author | Matthew Heon <matthew.heon@gmail.com> | 2018-03-14 15:14:49 -0400 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-03-15 17:45:11 +0000 |
commit | 55f2f58145e9871c299456cff8285a6d2595da86 (patch) | |
tree | 78f6aa90a9fa25aa7db83ceb6cd88ac01918728d /libpod/pod.go | |
parent | 4739fc2d98baf0ccfc46ae3ef770243bbdcea47a (diff) | |
download | podman-55f2f58145e9871c299456cff8285a6d2595da86.tar.gz podman-55f2f58145e9871c299456cff8285a6d2595da86.tar.bz2 podman-55f2f58145e9871c299456cff8285a6d2595da86.zip |
Add StartAndAttach() API endpoint for containers
This solves our prior problems with attach races by ensuring the
order is correct.
Also contains substantial cleanups to the attach code.
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
Closes: #482
Approved by: baude
Diffstat (limited to 'libpod/pod.go')
-rw-r--r-- | libpod/pod.go | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/libpod/pod.go b/libpod/pod.go index bd02efdae..16b590a1c 100644 --- a/libpod/pod.go +++ b/libpod/pod.go @@ -240,14 +240,7 @@ func (p *Pod) Stop(cleanup bool) (map[string]error, error) { } if cleanup { - // Clean up storage to ensure we don't leave dangling mounts - if err := ctr.cleanupStorage(); err != nil { - ctrErrors[ctr.ID()] = err - continue - } - - // Clean up network namespace - if err := ctr.cleanupNetwork(); err != nil { + if err := ctr.cleanup(); err != nil { ctrErrors[ctr.ID()] = err } } |