summaryrefslogtreecommitdiffstats
path: root/deploy
diff options
context:
space:
mode:
authorZhijiang Hu <hu.zhijiang@zte.com.cn>2017-10-19 01:22:48 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-10-19 01:22:48 +0000
commitc4860a5ba7ae7d6d3dc5dcf365e61b68d61a8265 (patch)
treecfd42e135ffc5571ecc63aec8cbb36819ae3b06f /deploy
parent7e0f730d0926b5efb93fb749ddf3951266df8b9b (diff)
parent07ca3da85fdde4638a81d3be4563a01e35af5e77 (diff)
Merge "remove unused null value of assigned network"
Diffstat (limited to 'deploy')
-rwxr-xr-xdeploy/get_conf.py26
1 files changed, 13 insertions, 13 deletions
diff --git a/deploy/get_conf.py b/deploy/get_conf.py
index 4d112589..97d2feba 100755
--- a/deploy/get_conf.py
+++ b/deploy/get_conf.py
@@ -46,9 +46,9 @@ def network(network=None):
if net_plane == "TENANT":
net_plane = "physnet1"
network.pop('name')
- map = {}
- map[net_plane] = network
- return map
+ network_map = {}
+ network_map[net_plane] = network
+ return network_map
@decorator_mk('interfaces')
@@ -58,8 +58,8 @@ def interface(interface=None):
net_name = "physnet1"
interface_name = interface.get('interface', '')
map2 = {}
- map = {'ip': '', 'name': net_name}
- map2[interface_name] = [map]
+ interface_map = {'name': net_name}
+ map2[interface_name] = [interface_map]
return map2
@@ -67,25 +67,25 @@ def interface(interface=None):
def role(host=None):
hostname = host.get('name', '')
role = host.get('roles', '')
- map = {}
- map[hostname] = role
- return map
+ role_map = {}
+ role_map[hostname] = role
+ return role_map
@decorator_mk('hosts')
def host(host=None):
hostip = host.get('ip', [])
passwd = host.get('password', [])
- map = {}
- map = {'ip': hostip, 'passwd': passwd}
- return map
+ host_map = {}
+ host_map = {'ip': hostip, 'passwd': passwd}
+ return host_map
@decorator_mk('hosts')
def mac_address(host=None):
mac_addresses = host.get('mac_addresses', [])
- map = {host['name']: mac_addresses}
- return map
+ mac_addr_map = {host['name']: mac_addresses}
+ return mac_addr_map
def network_config_parse(network_data):