summaryrefslogtreecommitdiff
path: root/cmd/podman
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2022-01-11 16:15:56 -0500
committerGitHub <noreply@github.com>2022-01-11 16:15:56 -0500
commit3404ad042def1c02872f66836feae19c814901a4 (patch)
treea454ef259ab28f85b17f53b3273725480aa78515 /cmd/podman
parentc4142ce0cfff792092bf420950b1985058cc241c (diff)
parent8f2358eeaa59fe369eebc6186403f95c2d66e49b (diff)
downloadpodman-3404ad042def1c02872f66836feae19c814901a4.tar.gz
podman-3404ad042def1c02872f66836feae19c814901a4.tar.bz2
podman-3404ad042def1c02872f66836feae19c814901a4.zip
Merge pull request #12694 from rhatdan/depend
Add podman rm --depend
Diffstat (limited to 'cmd/podman')
-rw-r--r--cmd/podman/containers/rm.go3
-rw-r--r--cmd/podman/root.go4
-rw-r--r--cmd/podman/utils/error.go2
3 files changed, 5 insertions, 4 deletions
diff --git a/cmd/podman/containers/rm.go b/cmd/podman/containers/rm.go
index 70cb76693..cede0ba14 100644
--- a/cmd/podman/containers/rm.go
+++ b/cmd/podman/containers/rm.go
@@ -61,7 +61,8 @@ func rmFlags(cmd *cobra.Command) {
flags.BoolVarP(&rmOptions.All, "all", "a", false, "Remove all containers")
flags.BoolVarP(&rmOptions.Ignore, "ignore", "i", false, "Ignore errors when a specified container is missing")
- flags.BoolVarP(&rmOptions.Force, "force", "f", false, "Force removal of a running or unusable container. The default is false")
+ flags.BoolVarP(&rmOptions.Force, "force", "f", false, "Force removal of a running or unusable container")
+ flags.BoolVar(&rmOptions.Depend, "depend", false, "Remove container and all containers that depend on the selected container")
timeFlagName := "time"
flags.UintVarP(&stopTimeout, timeFlagName, "t", containerConfig.Engine.StopTimeout, "Seconds to wait for stop before killing the container")
_ = cmd.RegisterFlagCompletionFunc(timeFlagName, completion.AutocompleteNone)
diff --git a/cmd/podman/root.go b/cmd/podman/root.go
index bccc559ce..b695443c2 100644
--- a/cmd/podman/root.go
+++ b/cmd/podman/root.go
@@ -137,7 +137,7 @@ func persistentPreRunE(cmd *cobra.Command, args []string) error {
runtimeFlag := cmd.Root().Flags().Lookup("runtime")
if runtimeFlag == nil {
return errors.Errorf(
- "Unexcpected error setting runtime to '%s' for restore",
+ "setting runtime to '%s' for restore",
*runtime,
)
}
@@ -217,7 +217,7 @@ func persistentPreRunE(cmd *cobra.Command, args []string) error {
context := cmd.Root().LocalFlags().Lookup("context")
if context.Value.String() != "default" {
- return errors.New("Podman does not support swarm, the only --context value allowed is \"default\"")
+ return errors.New("podman does not support swarm, the only --context value allowed is \"default\"")
}
if !registry.IsRemote() {
if cmd.Flag("cpu-profile").Changed {
diff --git a/cmd/podman/utils/error.go b/cmd/podman/utils/error.go
index aab1da675..b3b54876f 100644
--- a/cmd/podman/utils/error.go
+++ b/cmd/podman/utils/error.go
@@ -27,7 +27,7 @@ func (o OutputErrors) PrintErrors() (lastError error) {
instead returns a message and we cast it to a new error.
Following function performs parsing on build error and returns
- exit status which was exepected for this current build
+ exit status which was expected for this current build
*/
func ExitCodeFromBuildError(errorMsg string) (int, error) {
if strings.Contains(errorMsg, "exit status") {