diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-06-08 14:45:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-08 14:45:24 +0200 |
commit | 39f5ea4c040d60f5f16b85ab144ddacf4cbba4c8 (patch) | |
tree | 001ee1a2377c342c616f300831375c42ae58c63f /libpod/container_api.go | |
parent | f6a2860b625a796bd9d6fd48e641b7f7fa50d28a (diff) | |
parent | 1be345bd9d82ac64d7ae3ceea41f72329f7bdebf (diff) | |
download | podman-39f5ea4c040d60f5f16b85ab144ddacf4cbba4c8.tar.gz podman-39f5ea4c040d60f5f16b85ab144ddacf4cbba4c8.tar.bz2 podman-39f5ea4c040d60f5f16b85ab144ddacf4cbba4c8.zip |
Merge pull request #3180 from mheon/inspect_volumes
Begin to break up pkg/inspect
Diffstat (limited to 'libpod/container_api.go')
-rw-r--r-- | libpod/container_api.go | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/libpod/container_api.go b/libpod/container_api.go index c27cb85ea..1894780de 100644 --- a/libpod/container_api.go +++ b/libpod/container_api.go @@ -10,9 +10,7 @@ import ( "sync" "time" - "github.com/containers/libpod/libpod/driver" "github.com/containers/libpod/libpod/events" - "github.com/containers/libpod/pkg/inspect" "github.com/containers/libpod/pkg/lookup" "github.com/containers/storage/pkg/stringid" "github.com/docker/docker/oci/caps" @@ -535,32 +533,6 @@ func (c *Container) RemoveArtifact(name string) error { return os.Remove(c.getArtifactPath(name)) } -// Inspect a container for low-level information -func (c *Container) Inspect(size bool) (*inspect.ContainerInspectData, error) { - if !c.batched { - c.lock.Lock() - defer c.lock.Unlock() - - if err := c.syncContainer(); err != nil { - return nil, err - } - } - - storeCtr, err := c.runtime.store.Container(c.ID()) - if err != nil { - return nil, errors.Wrapf(err, "error getting container from store %q", c.ID()) - } - layer, err := c.runtime.store.Layer(storeCtr.LayerID) - if err != nil { - return nil, errors.Wrapf(err, "error reading information about layer %q", storeCtr.LayerID) - } - driverData, err := driver.GetDriverData(c.runtime.store, layer.ID) - if err != nil { - return nil, errors.Wrapf(err, "error getting graph driver info %q", c.ID()) - } - return c.getContainerInspectData(size, driverData) -} - // Wait blocks until the container exits and returns its exit code. func (c *Container) Wait() (int32, error) { return c.WaitWithInterval(DefaultWaitInterval) |