summaryrefslogtreecommitdiff
path: root/cmd/podman/images/prune.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/podman/images/prune.go')
-rw-r--r--cmd/podman/images/prune.go10
1 files changed, 9 insertions, 1 deletions
diff --git a/cmd/podman/images/prune.go b/cmd/podman/images/prune.go
index a082255f6..6ecf4f2aa 100644
--- a/cmd/podman/images/prune.go
+++ b/cmd/podman/images/prune.go
@@ -59,7 +59,15 @@ func prune(cmd *cobra.Command, args []string) error {
return nil
}
}
-
+ filterMap, err := common.ParseFilters(filter)
+ if err != nil {
+ return err
+ }
+ for k, v := range filterMap {
+ for _, val := range v {
+ pruneOpts.Filter = append(pruneOpts.Filter, fmt.Sprintf("%s=%s", k, val))
+ }
+ }
results, err := registry.ImageEngine().Prune(registry.GetContext(), pruneOpts)
if err != nil {
return err