summaryrefslogtreecommitdiff
path: root/cmd/podman/system.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-02-06 23:03:21 +0100
committerGitHub <noreply@github.com>2019-02-06 23:03:21 +0100
commitc7350721bff99fb4455a0ddb51e7155e04a9283d (patch)
tree9c5dd9778e8cdd8fc9f0b5880c3fdb7f9a615d61 /cmd/podman/system.go
parent72fcfb7e8624a4f61761d10f3bd80d9c6da3e31e (diff)
parent0830bb9035a9ee35810e358a32b8011da2dc1be6 (diff)
downloadpodman-c7350721bff99fb4455a0ddb51e7155e04a9283d.tar.gz
podman-c7350721bff99fb4455a0ddb51e7155e04a9283d.tar.bz2
podman-c7350721bff99fb4455a0ddb51e7155e04a9283d.zip
Merge pull request #2252 from rhatdan/system
Add podman system prune and info commands
Diffstat (limited to 'cmd/podman/system.go')
-rw-r--r--cmd/podman/system.go29
1 files changed, 29 insertions, 0 deletions
diff --git a/cmd/podman/system.go b/cmd/podman/system.go
new file mode 100644
index 000000000..9596252ad
--- /dev/null
+++ b/cmd/podman/system.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "sort"
+
+ "github.com/urfave/cli"
+)
+
+var (
+ systemSubCommands = []cli.Command{
+ pruneSystemCommand,
+ }
+ systemDescription = "Manage podman"
+ systemCommand = cli.Command{
+ Name: "system",
+ Usage: "Manage podman",
+ Description: systemDescription,
+ ArgsUsage: "",
+ Subcommands: getSystemSubCommandsSorted(),
+ UseShortOptionHandling: true,
+ OnUsageError: usageErrorHandler,
+ }
+)
+
+func getSystemSubCommandsSorted() []cli.Command {
+ systemSubCommands = append(systemSubCommands, getSystemSubCommands()...)
+ sort.Sort(commandSortedAlpha{systemSubCommands})
+ return systemSubCommands
+}