diff options
author | Yves-Alexis Perez <corsac@debian.org> | 2016-03-24 11:59:32 +0100 |
---|---|---|
committer | Yves-Alexis Perez <corsac@debian.org> | 2016-03-24 11:59:32 +0100 |
commit | 518dd33c94e041db0444c7d1f33da363bb8e3faf (patch) | |
tree | e8d1665ffadff7ec40228dda47e81f8f4691cd07 /testing/hosts/default | |
parent | f42f239a632306ed082f6fde878977248eea85cf (diff) | |
download | vyos-strongswan-518dd33c94e041db0444c7d1f33da363bb8e3faf.tar.gz vyos-strongswan-518dd33c94e041db0444c7d1f33da363bb8e3faf.zip |
Imported Upstream version 5.4.0
Diffstat (limited to 'testing/hosts/default')
-rwxr-xr-x | testing/hosts/default/usr/local/bin/expect-connection | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/testing/hosts/default/usr/local/bin/expect-connection b/testing/hosts/default/usr/local/bin/expect-connection index 10a709255..17e2b7fbe 100755 --- a/testing/hosts/default/usr/local/bin/expect-connection +++ b/testing/hosts/default/usr/local/bin/expect-connection @@ -15,10 +15,16 @@ fi secs=$2 [ ! $secs ] && secs=5 +cmd="swanctl --list-conns" +grep 'load.*stroke' /etc/strongswan.conf >/dev/null +if [ $? -eq 0 ]; then + cmd="ipsec statusall" +fi + let steps=$secs*10 for i in `seq 1 $steps` do - ipsec statusall 2>&1 | grep ^[[:space:]]*$1: >/dev/null + $cmd 2>&1 | grep ^[[:space:]]*$1: >/dev/null [ $? -eq 0 ] && exit 0 sleep 0.1 done |