mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
libvirt-guests: avoid bashism
At least Debian uses dash to run the init scripts
This commit is contained in:
parent
d9de144385
commit
5a05865773
@ -89,13 +89,15 @@ test_connect()
|
||||
{
|
||||
uri=$1
|
||||
|
||||
for ((i = 0; i < ${CONNECT_RETRIES}; i++)); do
|
||||
i=${CONNECT_RETRIES}
|
||||
while [ $i -gt 0 ]; do
|
||||
run_virsh "$uri" connect 2>/dev/null
|
||||
if [ $? -eq 0 ]; then
|
||||
return 0;
|
||||
fi
|
||||
sleep ${RETRIES_SLEEP}
|
||||
eval_gettext "Unable to connect to libvirt currently. Retrying .. \$i"
|
||||
i=$(($i-1))
|
||||
done
|
||||
eval_gettext "Can't connect to \$uri. Skipping."
|
||||
echo
|
||||
|
Loading…
Reference in New Issue
Block a user