It is possible for provider.authorize to exist, but set to None. Rather
then loading this value blindly, assume the default is False.
File "/home/zuul/src/github.com/ansible/ansible/lib/ansible/executor/task_executor.py", line 145, in run
res = self._execute()
File "/home/zuul/src/github.com/ansible/ansible/lib/ansible/executor/task_executor.py", line 635, in _execute
result = self._handler.run(task_vars=variables)
File "/home/zuul/src/github.com/ansible/ansible/lib/ansible/plugins/action/ios.py", line 50, in run
provider = load_provider(ios_provider_spec, self._task.args)
File "/home/zuul/src/github.com/ansible/ansible/lib/ansible/module_utils/network/common/utils.py", line 424, in load_provider
provider['authorize'] = boolean(provider['authorize'])
File "/home/zuul/src/github.com/ansible/ansible/lib/ansible/module_utils/parsing/convert_bool.py", line 26, in boolean
raise TypeError("The value '%s' is not a valid boolean. Valid booleans include: %s" % (to_text(value), ', '.join(repr(i) for i in BOOLEANS)))
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
* Add support to start a vm and put it on hold in one_vm
* Add version_added to vm_start_on_hold option for one_vm
* Add version_added to vm_start_on_hold option for one_vm#2
* Add version_added to vm_start_on_hold option for one_vm#3
* Fix indentation for one_vm
* route53_facts: add check mode support
* route53_facts: add changelog fragment mentioning check mode support
* route53_facts: alter changelog fragment type from `minor_changes` to `bugfixes`
* Update changelogs/fragments/56900-route53-facts-check-mode.yaml
Co-Authored-By: Felix Fontein <felix@fontein.de>
dict.items() in pytho2 returns a list of tuples which can be iterated
while modifying the dict. In python 3 it returns a view which is tied to
the underlying dict, meaning the modifications to the dict while
iterating are unsafe.
This commit generates new list containing the tuples from the iterator
in python 3 which breaks the link to the dict, allowing the dict to be
modified while iterating the list.
In python 2 it would simply copy the list.
Fixes#56902
* [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>
The "-" does not work as expected if I want to get a specific version of a package. After replacing the dash with the equal sign. the task passed successfully.
Depends on package manager - adds example so we show both syntaxes.
* openstacksdk < 0.10.0: fix AttributeError
`openstack.version.__version__` expression raises an `AttributeError`
exception when openstacksdk < 0.10.0 is used. `openstack.version` is
now imported as a module, which works for all openstacksdk versions.
Error was:
The full traceback is:
Traceback (most recent call last):
File "$HOME/.ansible/tmp/ansible-tmp-1545612308.8-46792777824159/AnsiballZ_os_security_group.py", line 113, in <module>
_ansiballz_main()
File "$HOME/.ansible/tmp/ansible-tmp-1545612308.8-46792777824159/AnsiballZ_os_security_group.py", line 105, in _ansiballz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "$HOME/.ansible/tmp/ansible-tmp-1545612308.8-46792777824159/AnsiballZ_os_security_group.py", line 48, in invoke_module
imp.load_module('__main__', mod, module, MOD_DESC)
File "/tmp/ansible_os_security_group_payload_keFTIJ/__main__.py", line 163, in <module>
File "/tmp/ansible_os_security_group_payload_keFTIJ/__main__.py", line 115, in main
File "/tmp/ansible_os_security_group_payload_keFTIJ/ansible_os_security_group_payload.zip/ansible/module_utils/openstack.py", line 121, in openstack_cloud_from_module
AttributeError: 'module' object has no attribute 'version'
* Add missing space & dot in error message
* Always require openstacksdk >= 0.12
According to the OpenStack Networking API
the attribute binding:vnic_type of a port is optional.
This change enables the os_port module to handle
binding:vnic_type as optional.
* Returns zone ID for existing zone or `null`
* route53_zone: add module unit tests
* route53_zone: add compatibility with Python 2.6 to the unit tests
* route53_zone: address pycodestyle warning (add blank line)
Until now, the module was only able to interact with vcenter. This
commit adds the ability to directly target an ESXi without the
`esxi_hostname` parameter.
- 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
The `network.type` parameter is set to default on default on `static`.
As a consequence, the network parameter is always defined as `dict`.
This patch ensures we don't check the value of the network configuration
if we want to delete the interface.
* Make datacenter as alias and optional
* Add folder param to place datastore cluster in specific folder
* Updated examples
* Updated tests
Fixes: #48010
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>