|
|
@ -37,13 +37,14 @@ except ImportError:
|
|
|
|
class ActionModule(_ActionModule):
|
|
|
|
class ActionModule(_ActionModule):
|
|
|
|
|
|
|
|
|
|
|
|
def run(self, tmp=None, task_vars=None):
|
|
|
|
def run(self, tmp=None, task_vars=None):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if self._play_context.connection == 'local':
|
|
|
|
provider = load_provider(eos_provider_spec, self._task.args)
|
|
|
|
provider = load_provider(eos_provider_spec, self._task.args)
|
|
|
|
transport = provider['transport'] or 'cli'
|
|
|
|
transport = provider['transport'] or 'cli'
|
|
|
|
|
|
|
|
|
|
|
|
display.vvvv('connection transport is %s' % transport, self._play_context.remote_addr)
|
|
|
|
display.vvvv('connection transport is %s' % transport, self._play_context.remote_addr)
|
|
|
|
|
|
|
|
|
|
|
|
if transport == 'cli':
|
|
|
|
if transport == 'cli':
|
|
|
|
if self._play_context.connection == 'local':
|
|
|
|
|
|
|
|
pc = copy.deepcopy(self._play_context)
|
|
|
|
pc = copy.deepcopy(self._play_context)
|
|
|
|
pc.connection = 'network_cli'
|
|
|
|
pc.connection = 'network_cli'
|
|
|
|
pc.network_os = 'eos'
|
|
|
|
pc.network_os = 'eos'
|
|
|
|