mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 03:41:25 -07:00
Fix network modules for ziploader changes
This commit is contained in:
parent
54a3a14428
commit
77e3dc9e6a
6 changed files with 26 additions and 28 deletions
|
@ -194,16 +194,15 @@ class NetworkModule(AnsibleModule):
|
|||
return self._config
|
||||
|
||||
def _load_params(self):
|
||||
params = super(NetworkModule, self)._load_params()
|
||||
provider = params.get('provider') or dict()
|
||||
super(NetworkModule, self)._load_params()
|
||||
provider = self.params.get('provider') or dict()
|
||||
for key, value in provider.items():
|
||||
if key in NET_COMMON_ARGS:
|
||||
if params.get(key) is None and value is not None:
|
||||
params[key] = value
|
||||
if self.params.get(key) is None and value is not None:
|
||||
self.params[key] = value
|
||||
for key, env_var in NET_ENV_ARGS.items():
|
||||
if params.get(key) is None and env_var in os.environ:
|
||||
params[key] = os.environ[env_var]
|
||||
return params
|
||||
if self.params.get(key) is None and env_var in os.environ:
|
||||
self.params[key] = os.environ[env_var]
|
||||
|
||||
def connect(self):
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue