Check the existence of 'forceencap' parameter before use
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/709be45c Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/709be45c Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/709be45c Branch: refs/heads/4.7 Commit: 709be45cf0f32bacc54ec2384be9e54bd62a5acf Parents: 18d5cd2 Author: Boris Schrijver <[email protected]> Authored: Fri Feb 5 21:06:53 2016 +0100 Committer: Boris Schrijver <[email protected]> Committed: Fri Feb 5 21:06:53 2016 +0100 ---------------------------------------------------------------------- systemvm/patches/debian/config/opt/cloud/bin/configure.py | 2 ++ 1 file changed, 2 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/709be45c/systemvm/patches/debian/config/opt/cloud/bin/configure.py ---------------------------------------------------------------------- diff --git a/systemvm/patches/debian/config/opt/cloud/bin/configure.py b/systemvm/patches/debian/config/opt/cloud/bin/configure.py index 840c7cb..f317b87 100755 --- a/systemvm/patches/debian/config/opt/cloud/bin/configure.py +++ b/systemvm/patches/debian/config/opt/cloud/bin/configure.py @@ -520,6 +520,8 @@ class CsSite2SiteVpn(CsDataBag): file.addeq(" pfs=%s" % CsHelper.bool_to_yn(obj['dpd'])) file.addeq(" keyingtries=2") file.addeq(" auto=start") + if not obj.has_key('encap'): + obj['encap']="false" file.addeq(" forceencaps=%s" % CsHelper.bool_to_yn(obj['encap'])) if obj['dpd']: file.addeq(" dpddelay=30")
