From c0f476e2f269cba14debc4cb448ba13563ad4117 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Wed, 17 Apr 2019 12:49:46 +0200 Subject: [PATCH] Use more appropriate API to check if the container already exists https://github.com/debarshiray/toolbox/pull/122 --- toolbox | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolbox b/toolbox index 4e339df..03e98d8 100755 --- a/toolbox +++ b/toolbox @@ -691,7 +691,7 @@ create() echo "$base_toolbox_command: checking if container $toolbox_container already exists" >&3 enter_command=$(create_enter_command "$toolbox_container") - if $prefix_sudo podman inspect --type container $toolbox_container >/dev/null 2>&3; then + if $prefix_sudo podman container exists $toolbox_container >/dev/null 2>&3; then echo "$base_toolbox_command: container $toolbox_container already exists" >&2 echo "Enter with: $enter_command" >&2 echo "Try '$base_toolbox_command --help' for more information." >&2