Skip to content

Commit 5375368

Browse files
vaidyasdDaanHoogland
authored andcommitted
- Created new devcloud advanced networking config file (devcloud-advanced_juniper-contrail.cfg). - Modification to deployDataCenter script, to enable "JuniperContrailRouter" & "JuniperContrailVpcRouter" providers.
Signed-off-by: Daan Hoogland <daan@onecht.net>
1 parent 53ee9ae commit 5375368

2 files changed

Lines changed: 130 additions & 0 deletions

File tree

Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
#
18+
# This configuration is meant for running advanced networking , with management server on the laptop,
19+
# It requires that the user run a DNS resolver within devcloud via 'apt-get install dnsmasq'
20+
#
21+
#
22+
{
23+
"zones": [
24+
{
25+
"localstorageenabled": "true",
26+
"name": "default",
27+
"dns1": "8.8.8.8",
28+
"physical_networks": [
29+
{
30+
"broadcastdomainrange": "Zone",
31+
"name": "ip-fabric",
32+
"traffictypes": [
33+
{
34+
"xen": "Pool-wide network associated with eth0",
35+
"typ": "Management"
36+
},
37+
{
38+
"xen": "Pool-wide network associated with eth0",
39+
"typ": "Guest"
40+
},
41+
{
42+
"xen": "Pool-wide network associated with eth1",
43+
"typ": "Public"
44+
}
45+
],
46+
"providers": [
47+
{
48+
"broadcastdomainrange": "ZONE",
49+
"name": "JuniperContrailRouter"
50+
}
51+
],
52+
"isolationmethods": [
53+
"L3VPN"
54+
]
55+
}
56+
],
57+
"ipranges": [
58+
{
59+
"startip": "10.0.3.100",
60+
"endip": "10.0.3.199",
61+
"netmask": "255.255.255.0",
62+
"vlan": "untagged",
63+
"gateway": "10.0.3.2"
64+
}
65+
],
66+
"networktype": "Advanced",
67+
"pods": [
68+
{
69+
"endip": "192.168.56.249",
70+
"name": "a6",
71+
"startip": "192.168.56.200",
72+
"netmask": "255.255.255.0",
73+
"clusters": [
74+
{
75+
"clustername": "a6-xen",
76+
"hypervisor": "XenServer",
77+
"hosts": [
78+
{
79+
"username": "root",
80+
"url": "http://192.168.56.10/",
81+
"password": "password"
82+
}
83+
],
84+
"clustertype": "CloudManaged"
85+
}
86+
],
87+
"gateway": "192.168.56.1"
88+
}
89+
],
90+
"internaldns1": "192.168.56.10",
91+
"secondaryStorages": [
92+
{
93+
"url": "nfs://192.168.56.10:/opt/storage/secondary",
94+
"provider": "NFS",
95+
"details": [ ]
96+
}
97+
]
98+
}
99+
],
100+
"dbSvr": {
101+
"dbSvr": "127.0.0.1",
102+
"passwd": "cloud",
103+
"db": "cloud",
104+
"port": 3306,
105+
"user": "cloud"
106+
},
107+
"logger": [
108+
{
109+
"name": "TestClient",
110+
"file": "/var/log/testclient.log"
111+
},
112+
{
113+
"name": "TestCase",
114+
"file": "/var/log/testcase.log"
115+
}
116+
],
117+
"mgtSvr": [
118+
{
119+
"mgtSvrIp": "127.0.0.1",
120+
"port": 8096
121+
}
122+
]
123+
}

tools/marvin/marvin/deployDataCenter.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -516,6 +516,13 @@ def configureProviders(self, phynetwrk, providers):
516516
self.enableProvider(pnetprovres[0].id)
517517
elif provider.name == 'SecurityGroupProvider':
518518
self.enableProvider(pnetprovres[0].id)
519+
elif provider.name in ['JuniperContrailRouter', 'JuniperContrailVpcRouter']:
520+
netprov = addNetworkServiceProvider.\
521+
addNetworkServiceProviderCmd()
522+
netprov.name = provider.name
523+
netprov.physicalnetworkid = phynetwrk.id
524+
result = self.__apiClient.addNetworkServiceProvider(netprov)
525+
self.enableProvider(result.id)
519526
elif provider.name in ['Netscaler', 'JuniperSRX', 'F5BigIp']:
520527
netprov = addNetworkServiceProvider.\
521528
addNetworkServiceProviderCmd()

0 commit comments

Comments
 (0)