mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-04 18:14:05 +00:00
lxc-destroy: wait until the container is stopped
Signed-off-by: Timothy Chen <tnachen@gmail.com> Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com> Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
This commit is contained in:
parent
b505cccf4d
commit
d1252b8425
@ -99,6 +99,7 @@ lxc-info -n $lxc_name 2>/dev/null | grep -q RUNNING
|
||||
if [ $? -eq 0 ]; then
|
||||
if [ $force -eq 1 ]; then
|
||||
lxc-stop -n $lxc_name
|
||||
lxc-wait -n $lxc_name -s STOPPED
|
||||
else
|
||||
echo "$(basename $0): '$lxc_name' is running; aborted" >&2
|
||||
exit 1
|
||||
|
Loading…
Reference in New Issue
Block a user