summaryrefslogtreecommitdiffstats
path: root/ci/deploy.py
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2016-06-02 01:59:09 -0500
committerNarinder Gupta <narinder.gupta@canonical.com>2016-06-02 02:05:08 -0500
commit53447be957517322501caf7c2d441693c350d73f (patch)
tree47d037e4a34e1af63bf008898795b58c1d98c99d /ci/deploy.py
parentcceaaac23491b76e3e095dcb44e3e03c3d6247d0 (diff)
remove the ext-port and data network dependency on the labs.
All data will be captured from labconfig.yaml Change-Id: I11a2431b3896a65dc74cc0423a1b03050ef16146 Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci/deploy.py')
-rw-r--r--ci/deploy.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/ci/deploy.py b/ci/deploy.py
index cfd744d7..dadc964a 100644
--- a/ci/deploy.py
+++ b/ci/deploy.py
@@ -52,9 +52,10 @@ opnfvcfg['demo-maas']={'juju-bootstrap':{'memory': 4096,'name': "bootstrap",\
}\
}
+opnfvcfg['opnfv']={'ext-port':'','floating-ip-range':'','dataNetwork':''}
-opnfvcfg['demo-maas']['maas']['apt_sources'].append("ppa:maas/stable")
-opnfvcfg['demo-maas']['maas']['apt_sources'].append("ppa:juju/stable")
+opnfvcfg['demo-maas']['maas']['apt_sources'].append("ppa:maas/stable")
+opnfvcfg['demo-maas']['maas']['apt_sources'].append("ppa:juju/stable")
# lets modify the maas general settings:
@@ -84,6 +85,7 @@ while c < len(labcfg["opnfv"]["spaces"]):
ethbrAdmin = getFromDict(labcfg, ["opnfv","spaces",c,"bridge"])
brgway = getFromDict(labcfg, ["opnfv","spaces",c,"gateway"])
tmpcidr = brcidr[:-4]
+ opnfvcfg["opnfv"]["admNetwork"]=tmpcidr+"2"
nodegroup={"device": "eth"+str(y), "ip": tmpcidr+"5","subnet_mask": "255.255.255.0", \
"broadcast_ip": tmpcidr+"255", "router_ip": brgway,\
@@ -136,6 +138,8 @@ while c < len(labcfg["opnfv"]["spaces"]):
' address '+ipaddress+'\n'
' netmask 255.255.255.0\n')
opnfvcfg["demo-maas"]["juju-bootstrap"]["interfaces"].append("bridge="+brname+",model=virtio")
+ if brtype == "data":
+ opnfvcfg["opnfv"]["dataNetwork"]=brcidr
c=c+1
@@ -196,6 +200,9 @@ while c < len(labcfg["lab"]["racks"][0]["nodes"]):
c=c+1
+opnfvcfg["opnfv"]["floating-ip-range"]=labcfg["lab"]["racks"][0]["floating-ip-range"]
+opnfvcfg["opnfv"]["ext-port"]=labcfg["lab"]["racks"][0]["ext-port"]
+
with open('deployment.yaml', 'wa') as opnfvf:
yaml.dump(opnfvcfg, opnfvf, default_flow_style=False)