Tomas Herfert
1e36dfa2d0
adding "system ntp *" paths related to ROS7 ( #122 )
...
* adding "system ntp *" paths related to ROS7
Signed-off-by: Tomas Herfert <herfik>
* changelog
Signed-off-by: Tomas Herfert <herfik>
* docs
Signed-off-by: Tomas Herfert <herfik>
* typo
Signed-off-by: Tomas Herfert <herfik>
* sanity fix
Signed-off-by: Tomas Herfert <herfik>
* setting the correct defaults
Signed-off-by: Tomas Herfert <herfik>
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
* typo
Signed-off-by: Tomas Herfert <herfik>
Co-authored-by: Tomas Herfert <herfik>
Co-authored-by: Felix Fontein <felix@fontein.de>
2022-11-10 21:09:03 +01:00
Tomas Herfert
c2e58c3ae4
Interface list ( #120 )
...
* interface list & member
Signed-off-by: Tomas Herfert <herfik>
* adding changelog fragment
Signed-off-by: Tomas Herfert <herfik>
* changelog fix
Signed-off-by: Tomas Herfert <herfik>
* sanity fix
Signed-off-by: Tomas Herfert <herfik>
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
Signed-off-by: Tomas Herfert <herfik>
Co-authored-by: Tomas Herfert <herfik>
Co-authored-by: Felix Fontein <felix@fontein.de>
2022-11-09 21:10:25 +01:00
Felix Fontein
3c0ad57eb5
Extend API support. ( #110 )
2022-09-11 17:25:25 +02:00
TobsA
776b599ffe
Added timeout setting for api. ( #109 )
...
* Added timeout setting for api.
* Added changelog fragment
* Added "version_added" to api doc
* Added "," for better diff
* Fixed case and punctuation in changelog
Co-authored-by: Felix Fontein <felix@fontein.de>
* Fixed url in changelog fragment
Co-authored-by: Felix Fontein <felix@fontein.de>
2022-09-07 21:10:11 +02:00
Felix Fontein
f797b4a231
Support absent values. Support absent value 'all' for 'server' in /ip dhcp-server lease. ( #107 )
2022-08-13 10:55:37 +02:00
Felix Fontein
a2ace3fb79
Add missing options for 'ip dhcp-server network'. ( #106 )
2022-08-13 10:54:48 +02:00
Felix Fontein
2911710f1b
Add api_info and api_modify modules ( #91 )
...
* Add api_info and api_modify modules.
* Add documentation, and cross-references for the modules.
* Bump version added for new modules.
* Ignore dynamic entries. Allow _info module to return them.
* Document behavior for dynamic entries.
* Update license headers.
* Add disclaimer.
* Improve formulation.
* Auto-generate path list in DOCUMENTATION.
* Add test to make sure lists have been generated automatically.
2022-07-31 22:06:19 +02:00
Felix Fontein
7973f58661
Move licenses to LICENSES/, use SPDX-License-Identifier, mention all licenses in galaxy.yml, add missing license file ( #101 )
...
* Add SPDX license identifiers, mention all licenses in galaxy.yml.
* Add default copyright headers.
* Adjust remaining/missing entries.
* Fix/add more copyright statements.
* Add sanity test.
* Add changelog.
* Add missing license file.
* Remove colon after 'Copyright'.
* Avoid colon after 'Copyright' in lint script.
2022-07-18 23:16:54 +02:00
Felix Fontein
023f11f7e1
Add encoding option to API modules ( #95 )
...
* Set encoding to UTF-8.
* Add encoding parameter to API modules.
* librouteros is now patched.
2022-05-24 22:19:26 +02:00
Felix Fontein
ff66ba9289
Add api_find_and_modify module. ( #93 )
2022-05-24 18:23:44 +02:00
Felix Fontein
3d80ccec5f
Add api_facts module ( #88 )
...
* Add API docs fragment.
* Improve documentation.
* Move API code to api module_utils.
* Improve docs.
* Add api_facts module.
Does not yet support 'config'. I'm not sure whether that's actually
possible with the API.
* Convert subnet to integer if possible.
* Cleanup.
* Linting and fix tests.
* Remove things that make no sense.
* Simplify code.
* Add basic tests.
* Lint.
2022-05-12 16:17:43 +02:00
Felix Fontein
a90c696589
Correctly handle \_ escape sequence. ( #89 )
2022-05-09 22:09:08 +02:00
Felix Fontein
d73eb1c144
Add module_utils and filters for quoting and unquoting ( #53 )
...
* Move splitting code to own file.
* Move list to dictionary code to quoting as well.
* Add quoting functionality.
* Add quoting filters.
* Add integration tests to CI.
* Fix bugs, increase coverage.
* Make parsing more strict.
* Extract function parse_argument_value from split_routeros_command to make proper parsing of WHERE possible.
* Adjust expected error message in integration tests.
* Simplify code and improve coverage.
* Add changelog fragment for WHERE strictness in api module.
* Add documenation.
* Fix typo.
* Add documentation references.
* Add example to api module which uses quote_argument_value.
* Fix bug, and add tests which prevent this in the future.
* Add more escape sequence tests.
* Make sure all control characters are quoted.
2021-10-12 00:44:40 +03:00
Felix Fontein
937aa0dbfa
Replace ansible.module_utils._text by ansible.module_utils.common.text.converters ( #38 )
...
* Replace ansible.module_utils._text by ansible.module_utils.common.text.converters.
* One more.
2021-06-27 09:53:45 +02:00
Renato Almeida de Oliveira
e5ad772703
Change to_text for to_native ( #5 )
2020-10-29 00:57:17 +03:00
Felix Fontein
6ccc2eab79
Add boilerplate ( #108 )
...
* Add boilerplate to doc_fragments and module_utils.
* Add boilerplate to unit tests.
* Add boilerplate to modules.
2020-10-26 15:18:40 +01:00
Renato Almeida de Oliveira
3634150468
routeros: Bug fix: Exception catching ( #27 )
...
* Bug fix: Exception catching
The function get_capabilities was failing to catch connections exceptions, what make an ugly output
OUTPUT BEFORE CHANGES:
The full traceback is:
Traceback (most recent call last):
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routeros_comle>
_ansiballz_main()
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routeros_comallz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routeros_com_module
runpy.run_module(mod_name='ansible.modules.network.routeros.command', init_globals=None, run_name='__main__', a
File "/usr/lib64/python2.7/runpy.py", line 176, in run_module
fname, loader, pkg_name)
File "/usr/lib64/python2.7/runpy.py", line 82, in _run_module_code
mod_name, mod_fname, mod_loader, pkg_name)
File "/usr/lib64/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/modules/network/routeros/r7, in <module>
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/modules/network/routeros/r7, in main
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/routein run_commands
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/routen get_connection
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/routen get_capabilities
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/connection.py
ansible.module_utils.connection.ConnectionError: Failed to authenticate: Authentication failed.
fatal: [MK]: FAILED! => changed=false
module_stderr: |-
Traceback (most recent call last):
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routerosmodule>
_ansiballz_main()
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routerosnsiballz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "/root/.ansible/tmp/ansible-local-20843l7aphwz5/ansible-tmp-1588555470.4121525-264386939405924/AnsiballZ_routerosvoke_module
runpy.run_module(mod_name='ansible.modules.network.routeros.command', init_globals=None, run_name='__main__
File "/usr/lib64/python2.7/runpy.py", line 176, in run_module
fname, loader, pkg_name)
File "/usr/lib64/python2.7/runpy.py", line 82, in _run_module_code
mod_name, mod_fname, mod_loader, pkg_name)
File "/usr/lib64/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/modules/network/routere 187, in <module>
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/modules/network/routere 157, in main
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/r25, in run_commands
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/r5, in get_connection
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/network/r9, in get_capabilities
File "/tmp/ansible_command_payload_XbsRY1/ansible_command_payload.zip/ansible/module_utils/connectio
ansible.module_utils.connection.ConnectionError: Failed to authenticate: Authentication failed.
module_stdout: ''
msg: |-
MODULE FAILURE
See stdout/stderr for the exact error
rc: 1
OUTPUT AFTER CHANGES
fatal: [MK]: FAILED! => changed=false
msg: 'Failed to authenticate: Authentication failed.'
* Lint Fix
* changelog fragment
* changelog update
* to_text refactoring
2020-10-26 15:18:40 +01:00
John R Barker
bcfea39ddc
Add networking ( #1 )
...
Initial commit of network content that was previously in community.general
2020-10-26 15:18:40 +01:00