cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject [1/3] git commit: updated refs/heads/4.4 to 47754a6
Date Tue, 09 Dec 2014 09:54:58 GMT
Repository: cloudstack
Updated Branches:
  refs/heads/4.4 af4d1a635 -> 47754a68a


add a flag -c whether or not to check the VPN on create

Changed default to no, as the other side may not be up yet.
If this check fails, the VPN enters Error state and will not
work. It's safe to just let it connect on its own so it will
connect when it can.

(cherry picked from commit f8d718e3e31ad517969663d24647fcbd9b50cc3d)


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/0d7087a8
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/0d7087a8
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/0d7087a8

Branch: refs/heads/4.4
Commit: 0d7087a85abc54a344b6638fc0d7f73d726a1e5e
Parents: af4d1a6
Author: Remi Bergsma <rbergsma@schubergphilis.com>
Authored: Mon Dec 8 18:59:16 2014 +0100
Committer: Daan Hoogland <daan@onecht.net>
Committed: Tue Dec 9 10:54:15 2014 +0100

----------------------------------------------------------------------
 .../patches/debian/config/opt/cloud/bin/ipsectunnel.sh    | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0d7087a8/systemvm/patches/debian/config/opt/cloud/bin/ipsectunnel.sh
----------------------------------------------------------------------
diff --git a/systemvm/patches/debian/config/opt/cloud/bin/ipsectunnel.sh b/systemvm/patches/debian/config/opt/cloud/bin/ipsectunnel.sh
index d30a9ca..809cb4d 100755
--- a/systemvm/patches/debian/config/opt/cloud/bin/ipsectunnel.sh
+++ b/systemvm/patches/debian/config/opt/cloud/bin/ipsectunnel.sh
@@ -23,7 +23,7 @@ vpnoutmark="0x525"
 vpninmark="0x524"
 
 usage() {
-    printf "Usage: %s: (-A|-D) -l <left-side vpn peer> -n <left-side guest cidr>
-g <left-side next hop> -r <right-side vpn peer> -N <right-side private subnets>
-e <esp policy> -i <ike policy> -t <ike lifetime> -T <esp lifetime>
-s <pre-shared secret> -d <dpd 0 or 1> [ -p <passive or not> ]\n" $(basename
$0) >&2
+    printf "Usage: %s: (-A|-D) -l <left-side vpn peer> -n <left-side guest cidr>
-g <left-side next hop> -r <right-side vpn peer> -N <right-side private subnets>
-e <esp policy> -i <ike policy> -t <ike lifetime> -T <esp lifetime>
-s <pre-shared secret> -d <dpd 0 or 1> [ -p <passive or not> -c <check
if up on creation ]\n" $(basename $0) >&2
 }
 
 #set -x
@@ -174,6 +174,9 @@ ipsec_tunnel_add() {
   if [ $passive -eq 0 ]
   then
       sudo ipsec auto --up vpn-$rightpeer
+  fi
+  if [ $checkup -eq 1 ]
+  then
 
     #5 seconds for checking if it's ready
     for i in {1..5}
@@ -209,8 +212,9 @@ Iflag=
 sflag=
 passive=0
 op=""
+checkup=0
 
-while getopts 'ADpl:n:g:r:N:e:i:t:T:s:d:' OPTION
+while getopts 'ADpcl:n:g:r:N:e:i:t:T:s:d:' OPTION
 do
   case $OPTION in
   A)    opflag=1
@@ -254,6 +258,8 @@ do
         ;;
   p)    passive=1
         ;;
+  c)    checkup=1
+        ;;
   ?)    usage
         exit 2
         ;;


Mime
View raw message