Peter Sprygada
911600acf9
update junos_command integration tests ( #22213 )
...
fixes integration test to check for full rpc-reply string when
converted from xml. This is a change from 2.2 as the rpc-reply tag
is no longer stripped off
2017-03-02 16:46:23 -06:00
Peter Sprygada
7b2c013e5a
returns xml as a display option to junos_command ( #21833 )
...
The display option xml as accidentially removed from the display
argument. This patch adds xml back as an option.
fixes #21823
2017-03-02 16:05:20 -06:00
Peter Sprygada
02d2b753db
refactors junos modules to support persistent socket connections ( #21365 )
...
* updates junos_netconf module
* updates junos_command module
* updates junos_config module
* updates _junos_template module
* adds junos_rpc module
* adds junos_user module
2017-02-16 10:53:03 -05:00
Matt Martz
7c00346714
Validate EXAMPLES as YAML
2017-02-15 13:01:43 -08:00
Ganesh Nalawade
ee5d5c3e84
Fix #4103 Support json format in junos_command module ( #19045 )
2016-12-15 16:01:23 -05:00
Toshio Kuratomi
7319104552
Refreshed metadata for core modules
2016-12-08 11:25:35 -05:00
John R Barker
25b6492d37
Bulk spelling improvement to modules-core ( #5225 )
...
* Correct spelling mistakes
* Correct more spelling issues
* merge conflict
* Revert typo in parms
2016-12-08 11:25:20 -05:00
Peter Sprygada
9c664f424e
adds exception handling for adding an invalid condition ( #5125 )
...
This change will now handle a problem adding a condition that raises
an AddConditionError and return a well formed error to the user.
2016-12-08 11:25:18 -05:00
Peter Sprygada
58a5ec6c51
fixes junos_command module paring of wait_for strings ( #5083 )
...
The junos_command module wasn't properly parsing strings to apply
conditionals due to the return value not being converted to json
before the results where handed to the runner.
2016-12-08 11:25:15 -05:00
Peter Sprygada
73cf85d677
catches exception if conditional cannot be parsed ( #5067 )
...
If the conditional cannot be parsed, the module will now catch the exception
and return a well formed failed message.
fixes #5060
2016-12-08 11:25:14 -05:00
Nathaniel Case
aa82f48dc8
Network module code cleanup ( #5061 )
...
* Fix imports in junos_template
* Python 3 compatibility in eos_command
* Python 3 compatibility for ios_command
* Clean up issues with ios_facts
* Python 3 compatibility for ios_facts
* Import shuffle in ios_template
* Python 3 compatibility for iosxr_command
* Clean up iosxr_facts.py
* Python 3 compatibility for iosxr_facts
* Python 3 compatibility for junos_command
* Python 3 compatibility for ops_command
* Cleanup issues with ops_facts
* Python 3 compatibility for ops_facts
* Cleanup issues with ops_template
* Python 3 compatibility for vyos_command
* Cleanup issues with vyos_facts
* Python 3 compatibility for vyos_facts
2016-12-08 11:25:14 -05:00
Peter Sprygada
0ef16b44ca
fixes exception being raised when show configuration command issued ( #5047 )
...
The junos_command expects commands to be returned as xml by default but
`show configuration [options]` will return text not xml. This fix
will set the output format for any command that starts with `show
configuration` to text
fixes #4628
2016-12-08 11:25:14 -05:00
Peter Sprygada
a5b32fa0d1
fixes return passing output from command through jxmlease in junos_command ( #5044 )
...
The return string from the commands was not being passed through the
jxmlease library and therefore being returned as a string instead of a
json data structure. This also adds back the missing xml key in the
return that includes the raw xml string.
fixes #5001
2016-12-08 11:25:14 -05:00
Peter Sprygada
b9cb9d6345
fix import in junos_command module ( #4927 )
...
This fixes the import statements in the junos_command module to be
consistent with all junos_* modules
2016-12-08 11:25:11 -05:00
Peter Sprygada
702efda508
add new functionality to junos_command module
...
* commands argument now accepts a dict arguments
* rpcs argument now accepts a dict argument
* waitfor has been renamed to wait_for with an alias to waitfor
* only show commands are allowd when check mode is specified
* config mode is no longer allowed in the command stack
* add argument match with valid values any, all
2016-12-08 11:24:58 -05:00
codyrat
c4d5b13c8f
re.match for numeric only for kwargs[key] = int(value) ( #4495 )
2016-12-08 11:24:52 -05:00
John Barker
d4200b0389
junos: Docs update
2016-12-08 11:24:48 -05:00
Michael Scherer
c0217e14a7
Convert the network subfolder to py3/py2.4 syntax ( #3690 )
2016-12-08 11:24:29 -05:00
Peter Sprygada
abb008dca7
fixes docstring format in junos_command
2016-12-08 11:24:21 -05:00
Peter Sprygada
923974e3c0
add support to junos_command module for netconf transport
...
This adds support for using netconf to the junos_command option and removes
the use of cli as a transport
2016-12-08 11:24:20 -05:00
Peter Sprygada
4f4bc9ed5c
update junos_command module return values
...
This minor update fixes the return values from the junos_command module
to be consistent with other network modules
2016-12-08 11:24:06 -05:00
Peter Sprygada
fb7d5e798c
initial add of junos_command module
...
This adds a new module, junos_command that can be used for sending commands
to Juniper JUNOS based devices. The junos_command module is implemented
over a cli transport
2016-12-08 11:24:05 -05:00