summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'cmd')
-rw-r--r--cmd/podman/mount.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/cmd/podman/mount.go b/cmd/podman/mount.go
index b053ef1e8..df1bacc5f 100644
--- a/cmd/podman/mount.go
+++ b/cmd/podman/mount.go
@@ -105,13 +105,15 @@ func mountCmd(c *cli.Context) error {
return errors.Wrapf(err2, "error reading list of all containers")
}
for _, container := range containers {
- mountPoint, err := container.Mountpoint()
+ mounted, mountPoint, err := container.Mounted()
if err != nil {
return errors.Wrapf(err, "error getting mountpoint for %q", container.ID())
}
- if mountPoint == "" {
+
+ if !mounted {
continue
}
+
if json {
jsonMountPoints = append(jsonMountPoints, jsonMountPoint{ID: container.ID(), Names: []string{container.Name()}, MountPoint: mountPoint})
continue