Merge pull request #561 from weitzj/bugfix/docker-extra-params
Fixes invalid dictionary access.
This commit is contained in:
commit
925c9ab42d
1 changed files with 3 additions and 1 deletions
|
@ -726,6 +726,8 @@ class DockerManager(object):
|
||||||
'name': self.module.params.get('name'),
|
'name': self.module.params.get('name'),
|
||||||
'stdin_open': self.module.params.get('stdin_open'),
|
'stdin_open': self.module.params.get('stdin_open'),
|
||||||
'tty': self.module.params.get('tty'),
|
'tty': self.module.params.get('tty'),
|
||||||
|
'dns': self.module.params.get('dns'),
|
||||||
|
'volumes_from': self.module.params.get('volumes_from'),
|
||||||
}
|
}
|
||||||
|
|
||||||
if params['dns'] is not None:
|
if params['dns'] is not None:
|
||||||
|
@ -783,7 +785,7 @@ class DockerManager(object):
|
||||||
'network_mode': self.module.params.get('net'),
|
'network_mode': self.module.params.get('net'),
|
||||||
}
|
}
|
||||||
|
|
||||||
optionals = []
|
optionals = {}
|
||||||
for optional_param in ('dns', 'volumes_from', 'restart_policy', 'restart_policy_retry'):
|
for optional_param in ('dns', 'volumes_from', 'restart_policy', 'restart_policy_retry'):
|
||||||
optionals[optional_param] = self.module.params.get(optional_param)
|
optionals[optional_param] = self.module.params.get(optional_param)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue