updates network_common lib (#21306)

* removes connection functions refactored into connection
* updates ComplexDict and ComplexList objects to use with AnsibleModule
* updates modules to add new argument to ComplexList & ComplexDict
This commit is contained in:
Peter Sprygada
2017-02-14 14:38:30 -05:00
committed by GitHub
parent 009ac075b7
commit b0c01bbb82
7 changed files with 111 additions and 103 deletions

View File

@@ -149,7 +149,7 @@ def parse_commands(module, warnings):
command=dict(key=True),
prompt=dict(),
response=dict()
))
), module)
commands = command(module.params['commands'])
for index, item in enumerate(commands):
if module.check_mode and not item['command'].startswith('show'):

View File

@@ -311,17 +311,17 @@ def map_params_to_obj(module):
domain_name = ComplexList(dict(
name=dict(key=True),
vrf=dict()
))
), module)
domain_search = ComplexList(dict(
name=dict(key=True),
vrf=dict()
))
), module)
name_servers = ComplexList(dict(
server=dict(key=True),
vrf=dict()
))
), module)
for arg, cast in [('domain_name', domain_name),
('domain_search', domain_search),