Use more appropriate API to check if the container already exists
https://github.com/debarshiray/toolbox/pull/122
This commit is contained in:
parent
8db3317807
commit
c0f476e2f2
1 changed files with 1 additions and 1 deletions
2
toolbox
2
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
|
||||
|
|
Loading…
Reference in a new issue