* [docker_network] Fix idempotency when using aux_addresses in ipam_config (#56901)
* [docker_network] Fix idempotency when using aux_addresses in ipam_config
Mismatch between keys returned by Docker API (AuxilliaryAddresses) vs
expected by Ansible module (aux_addresses) resulted in tasks always
have status 'changed'. The existing code normalizing one set of
keys to another missed this special case where converting
CamelCase to lowercase is not sufficent.
Please see
https://github.com/moby/moby/blob/master/api/types/network/network.go
for reference.
* Correct keywords formatting in changelog file
Co-Authored-By: Felix Fontein <felix@fontein.de>
(cherry picked from commit 37df89b2d8)
* docker_network: Integration tests for IPAM config idempotence (#56975)
Integration tests for pull request #56901 which fixes found issues with idempotence.
(cherry picked from commit 6a50c6aae4)
* [stable-2.8] eos_l2_interface handle "Interface does not exist" (#56787)
* Quick and dirty attempt to handle eapi error
* Well this should probably change
* Hopefully this works correctly?
* Fix check_rc handling with httpapi
* Add tests that should hopefully cover the error
* Fix warnings
* Improve tests.
(cherry picked from commit cebb363fcc)
Co-authored-by: Nathaniel Case <ncase@redhat.com>
* Add changelog
* Remove backport overreach
* Fix debug statements in new tests while I'm here
It is possible the EOS appliance doesn't have an IP address on the
management1 interface, instead just check we have found that interface.
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
(cherry picked from commit f9589bd)
Co-authored-by: Paul Belanger <pabelanger@redhat.com>
* [stable-2.8] eos_config: Fix test issues (#56180)
* Alter tests to pass
* Change diff_against to make changed work again
* Add another diff_against
* Expose supports_sessions across all EOS connection types
* Change session warning to failure
* supports_sessions needs to be a method to survive the rpc boundary
* Alter tests to match
(cherry picked from commit 0bead36)
* [stable-2.8] Don't fail trying to read boot image without enable (#56126)
Also add a message when network_os_image can't be acquired.
(cherry picked from commit 3d9da0c)
Co-authored-by: Nathaniel Case <ncase@redhat.com>
* Add changelog
* Fix changelog
- Also return url and update docs for other values to indicate they are only returned on success.
- Add integration tests
- Use info variable for common return values
- Use -1 as default status rather than None. This is lines up with with existing code in urls.py
- Add unit tests to ensure status and url are returned on failure
(cherry picked from commit 8f4f3750fe)
Co-authored-by: Sam Doran <sdoran@redhat.com>
* Make ansible adhoc work with include_role
Fix logic condition so that include_role works
without
```
ERROR! 'async_val' is not a valid attribute for a IncludeRole
The error appears to be in 'None': line 0, column 0, but may
be elsewhere in the file depending on the exact syntax problem.
(could not open file to display line)
```
* Add include_role test for adhoc
(cherry picked from commit cd95843ea5)
Avoid premature vars templating
* added tests
* avoid 'is template' warning in vars, since we want them for latter templating
(cherry picked from commit 1da47bfa8c)
* [stable-2.8] Whitelist listen as a valid keyword on TaskInclude (#56586)
* Whitelist listen as a valid keyword on TaskInclude. Fixes#56580
* Move 'listen' to HandlerTaskInclude
* Remove trailing newline
(cherry picked from commit 576593e)
Co-authored-by: Matt Martz <matt@sivel.net>
* Improvement on setting VALID_INCLUDE_KEYWORDS on HandlerTaskInclude (#56801)
(cherry picked from commit 8bb3274711)
Ensure the module still work with the ESXi where CustomFieldsManager
does not exist.
From: https://www.vmware.com/support/developer/converter-sdk/conv60_apireference/vim.CustomFieldsManager.html
The CustomFieldsManager object is used to add and remove custom fields to
managed entities.
The custom fields values set on managed entities are available through the
customValue property and through the summary objects for VirtualMachine
and HostSystem. They are not available directly through this managed object.
This functionality is only available through VirtualCenter.
Fixes: #56071
(cherry picked from commit cf78759f5b)
This is a sanity test cleanup to handle a known image bug with (N9K) I7 images.
The I7 image fails to enable some snmp trap link configs causing an idempotency failure in the sanity, so we're skipping the idempotence tests that involve this bug.
Tested on N9K images: 9.2(2), 7.0(3)I7.
(cherry picked from commit 4d46f44ff2)
* Fixes Netconf_config single parameter bug (#56138)
* Fixes Netconf_config single parameter bug
Fixes 56022
fixed get_config to not require multiple parameters to just run a backup
* Add Integration test for netconf_config
Associated with #56022
tests backup through netconf only using one parameter.
* Added debug to the begin and end of file
* Fix formatting of save config. #56022
* removed blank line at end: #56022
(cherry picked from commit 647ed207af)
* Fix netconf_config backup string issue (#56175)
* Convert the ElementTree object to string
before dumping the configuration in file.
(cherry picked from commit 9c5745ad21)
* Clarify that GPLv3+ module_utils need core team approval.
* Update docs/docsite/rst/dev_guide/shared_snippets/licensing.txt
Co-Authored-By: Sam Doran <sdoran@redhat.com>
* More 'module_util' -> 'file in module_utils'.
(cherry picked from commit 53ec9c8019)
* Update get_certificate.py with an example to calculate number of days until cert expires from get_certificate result.
* Update lib/ansible/modules/crypto/get_certificate.py
Co-Authored-By: Felix Fontein <felix@fontein.de>
(cherry picked from commit cb9be4ddaf)
* Add changelog fragment
* Fix IPv6 address parsing for py2.6, and add tests
* make sure hostname isn't None
(cherry picked from commit 493cf81)
Co-authored-by: Matt Martz <matt@sivel.net>
* Allow python_requirements_facts to cope with packages with dashes
```
python_requirements_facts:
dependencies:
- kubernetes-validate
```
should work as expected
(cherry picked from commit 5b3305c71505ffd4b0fd7dc5a6a17a4d5cb4cd77)
* Allow python_requirements_facts to cope with packages with dashes (#56166)
* Allow python_requirements_facts to cope with packages with dashes
```
python_requirements_facts:
dependencies:
- kubernetes-validate
```
should work as expected
* Ensure tests run for python_requirements_facts
(cherry picked from commit 8e1dd58c2b)
* Rewrite much of the execution of meraki_switchport
- Previous versions had problems with idempotency and allowed_vlans
* Modified payload creation
- Parameter map is used
- propsed is created using .copy()
- Much cleaner this way
* Add whitespace for lint
* Add bugfix snippet for changelog
(cherry picked from commit d59eb9edab)
* When not using file_per_task, make sure we don't prematurely close the perf files
* add changelog fragment
(cherry picked from commit 867e357)
Co-authored-by: Matt Martz <matt@sivel.net>
* fix bugs for ce (#54750)
* Update ce.py
while to_text(out, errors='surrogate_then_replace').strip().endswith(']'):
display.vvvv('wrong context, sending exit to device', self._play_context.remote_addr)
conn.exec_command('return')
out = conn.get_prompt()
connetion has no send_command function and ce device has no 'exit' command to return user-view(a correct context),but 'return' .command.
* Add files via upload
Some bugs fix.
* Add files via upload
fix some bugs
* fix a bug for ce_command
Running a command with prompt via ce_command, It doesn't work.The reason is that the key word for network_cli recognition is answer not response.
* fix bugs
fix bugs for ce modules
* Update ce.py
* Delete ce_ftp.py
need modify
* Delete ce_lacp.py
* Add files via upload
* Delete ce_aaa_server.py
* Delete ce_aaa_server_host.py
* Compatible with Python 3
Compatible with Python 3 and fix bugs for ce
* Update ce_aaa_server.py
* Add files via upload
modify doc
* Add files via upload
Compatible with Python 3 and fix bugs
* Add files via upload
Compatible with Python 3 and fix bugs
* Add files via upload
Cancellation of change
* Update ce_netconf.py
It is a bug that response has no xml attribute:line 183
* Add files via upload
* Add files via upload
Compatible with Python 3 and fix bugs
* updatp ce_config.py
a bug for this module.
(cherry picked from commit 1017f15c38)