diff options
author | baude <bbaude@redhat.com> | 2019-04-02 10:26:43 -0500 |
---|---|---|
committer | baude <bbaude@redhat.com> | 2019-04-04 14:41:50 -0500 |
commit | dc94dbd3c17c9011fc1e851694a2190dcf6c2b3c (patch) | |
tree | b887cd75144e555acfb4a346f43b89cdf5470d8c /pkg/adapter/runtime_remote.go | |
parent | 1759eb09e1c13bc8392d515d69ca93226d067c73 (diff) | |
download | podman-dc94dbd3c17c9011fc1e851694a2190dcf6c2b3c.tar.gz podman-dc94dbd3c17c9011fc1e851694a2190dcf6c2b3c.tar.bz2 podman-dc94dbd3c17c9011fc1e851694a2190dcf6c2b3c.zip |
podman-remote image tree
add the ability for the podman-remote client to be able to print an
image tree.
Signed-off-by: baude <bbaude@redhat.com>
Diffstat (limited to 'pkg/adapter/runtime_remote.go')
-rw-r--r-- | pkg/adapter/runtime_remote.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/pkg/adapter/runtime_remote.go b/pkg/adapter/runtime_remote.go index 978c9ffd8..807a9ad8f 100644 --- a/pkg/adapter/runtime_remote.go +++ b/pkg/adapter/runtime_remote.go @@ -82,6 +82,7 @@ type remoteImage struct { Digest digest.Digest isParent bool Runtime *LocalRuntime + TopLayer string } // Container ... @@ -147,6 +148,7 @@ func imageInListToContainerImage(i iopodman.Image, name string, runtime *LocalRu Names: i.RepoTags, isParent: i.IsParent, Runtime: runtime, + TopLayer: i.TopLayer, } return &ContainerImage{ri}, nil } @@ -280,6 +282,11 @@ func (ci *ContainerImage) Dangling() bool { return len(ci.Names()) == 0 } +// TopLayer returns an images top layer as a string +func (ci *ContainerImage) TopLayer() string { + return ci.remoteImage.TopLayer +} + // TagImage ... func (ci *ContainerImage) TagImage(tag string) error { _, err := iopodman.TagImage().Call(ci.Runtime.Conn, ci.ID(), tag) |