mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 11:51:26 -07:00
roll up of fixes in junos action plugin (#21624)
* calls open_shell() or open_session() depending on connection type * closes shell after module completion * adds open_session() to netconf
This commit is contained in:
parent
c68d81fe4f
commit
2f10bdf0c7
2 changed files with 20 additions and 11 deletions
|
@ -101,6 +101,9 @@ class Connection(ConnectionBase):
|
|||
def exec_command(self, request):
|
||||
"""Sends the request to the node and returns the reply
|
||||
"""
|
||||
if request == 'open_session()':
|
||||
return (0, 'ok', '')
|
||||
|
||||
req = to_ele(request)
|
||||
if req is None:
|
||||
return (1, '', 'unable to parse request')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue