mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 03:41:25 -07:00
updates network local actions to check for connection=local (#21437)
* updates vyos local action * updates ios local action
This commit is contained in:
parent
86e2feffc1
commit
381a045089
2 changed files with 26 additions and 9 deletions
|
@ -35,6 +35,13 @@ class ActionModule(_ActionModule):
|
|||
|
||||
def run(self, tmp=None, task_vars=None):
|
||||
|
||||
if self._play_context.connection != 'local':
|
||||
return dict(
|
||||
fail=True,
|
||||
msg='invalid connection specified, expected connection=local, '
|
||||
'got %s' % self._play_context.connection
|
||||
)
|
||||
|
||||
provider = self.load_provider()
|
||||
|
||||
pc = copy.deepcopy(self._play_context)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue