mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 03:41:25 -07:00
Remove provider (and transport, where applicable) from consideration when not using connection=local (#39555)
* Remove provider (and transport, where applicable) from consideration * Add tests that misplaced transport does not fail task
This commit is contained in:
parent
384a0d8b01
commit
c6270e15a6
14 changed files with 48 additions and 2 deletions
|
@ -47,6 +47,7 @@ class ActionModule(_ActionModule):
|
|||
provider = self._task.args.get('provider', {})
|
||||
if any(provider.values()):
|
||||
display.warning('provider is unnecessary when using network_cli and will be ignored')
|
||||
del self._task.args['provider']
|
||||
elif self._play_context.connection == 'local':
|
||||
provider = load_provider(ios_provider_spec, self._task.args)
|
||||
pc = copy.deepcopy(self._play_context)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue