Commit graph

27219 commits

Author SHA1 Message Date
Kevin Backhouse
79bb7bde5f apt_repository: Fix crash caused by cache.update() raising an IOError on timeout. (#51996)
* Fix crash caused by cache.update() raising an IOError on timeout.

* Add changelog fragment.
2019-05-29 15:59:51 -04:00
Felix Fontein
c47e9d22b4
Rename one_image_facts -> one_image_info (#57035)
* Rename one_image_facts -> one_image_info.

* Add changelog.

* Forgot symlink.
2019-05-29 21:23:25 +02:00
Fred-sun
ba18dd713a Update document related with azure_rm_keyvault module (#57110) 2019-05-29 14:15:36 -05:00
Fred-sun
163d3efbf8 Update azure_rm_image relate document (#57043) 2019-05-29 14:12:36 -05:00
szymon3
00067c8d54 Update rabbitmq_queue.py (#56912)
change description for when `state=absent`
2019-05-29 13:57:05 -05:00
Ian Wienand
39945b8570 Make query with errors='ignore' return a blank list (#57038)
The jinja2 query() function (or lookup with wantslist=True, which is
the same thing) should always return a list.

However, if you combine a query with errors='ignore' and take the
error path, the current code returns a None value.  This is important
in a case such as

 - name: Conditional include file
   import_tasks: '{{ item }}'
   vars:
     params:
       files:
         - path/file1.yaml
         - path/file2.yaml
   loop: "{{ q('first_found', params, errors='ignore') }}"

If neither file1.yaml or file2.yaml exist, this should do nothing by
returning an empty list to the loop.  Currently if you run the above
task you'll get a rather unhelpful:

 Invalid data passed to 'loop', it requires a list, got this instead: .

This change ensures that when a query ignores an error, it returns a
empty list.  The errors='ignore' case is tested in several variants
with first_found.  The extant (but deprecated) "skip: True" for
first_found doesn't seem to be explicitly tested; a test is added here
to avoid regressions before removal in 2.12.

This fixes a regression you'll hit if you follow the suggestion in the
deprecation message included with
e17a2b502d to use errors=ignore over
"skip: True" for first_found.  This change adds an example that points
out the query/lookup difference and also fixes the error message to
not mention the now deprecated "skip: True".

Closes #56775
2019-05-29 13:23:02 -04:00
xuxiaowei0512
b7f4e2a190 update ospf modules to fix bugs as software version changes (#56974) 2019-05-29 12:40:30 -04:00
xuxiaowei0512
0137c4343b update ce_ntp.py and remove the root tag name to find all nodes (#56976)
* add a maintainer

* update ce_ntp.py and remove the root tag name to find all node

* update ce_ntp.py and remove the root tag name to find all node
2019-05-29 12:39:37 -04:00
xuxiaowei0512
9e1f184b2d add terminal initial prompt for initial connection (#57057) 2019-05-29 12:37:13 -04:00
Pilou
e5b2e4c1ac tower_credential: ssh_key_data isn't a path anymore (#57113) 2019-05-29 11:15:45 -05:00
Fred-sun
8043940c93 Update azure_rm_devtestlabvirtualmachine relate document (#56828)
* Update azure_rm_devtestlabvirtualmachine documentation
2019-05-29 11:03:42 -05:00
Kevin Breit
7864df8cb9 meraki - Rewrite update requirement check (#48394)
* Rewrite idempotency check
- Check now operates recursively and works on multiple types
- Order of lists matter

* Remove blank line for lint

* Fixed idempotency checks in meraki_ssid
- New sanitize() method for finding keys unique in compared dicts
- Fixed bug in meraki_ssid where SSID specified by number breaks
  - This will require a backport
- Converted ignored_keys from tuple to list

* Made changes required for idempotency

* Add changelog fragment

* Add unidirectional option for testing

* Disable option 1 check

* General fixes for is_update_required testing
- Added commented out debug statements in method
- Fixed ignored_keys modifications

* Remove old commented algorithm
2019-05-29 10:18:01 -04:00
Kevin Breit
57e1063fc7 meraki_config_template - Remove mandatory network lookup (#56525)
* Module only makes network lookups when needed instead of every execution

* Formatting fixes
2019-05-29 19:27:38 +05:30
Rohit
b143918f30
text format fan info mismatch and module info check (#57009)
Signed-off-by: rohitthakur2590 <rohitthakur2590@outlook.com>
2019-05-29 19:08:46 +05:30
MyronFanQiu
a56a9e1eeb switch the deletion order (#57102) 2019-05-29 17:11:54 +08:00
Abhijeet Kasurde
2cf1dfc415 Fixed misc typos (#57103)
* Changed immuteable to immutable
* Changed conig to config

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2019-05-29 08:56:05 +02:00
Daniel Mellado Area
0ada6b8d8d Fix junos_facts test (#57065)
This commit fixes a non-passing junos_facts integration test, as it was
using a non-ordered frozenset to assert its result.
2019-05-28 20:25:45 -04:00
ShachafGoldstein
486370a744 Fix win_iis_virtualdirectory to remove a virtual directory that contains children (#56569)
* FIX #49755

* Added changelog fragment

* Changes according to review

* Fixed changelog
2019-05-29 05:59:50 +10:00
ShachafGoldstein
4490c0ba51 correct behaviour of win_iis when using site_id if site not found (#56567)
* Fixed #47057

* Fix trailing whitespace

* Change for review
2019-05-29 05:31:00 +10:00
ShachafGoldstein
94566ed79c Win_hostname module: Change name check to WMI (#56420)
* Change name check to WMI

* Changelog fragment

* Fixed per review
2019-05-29 05:30:16 +10:00
Ilya Zonov
35c8739c2a Add full change check for rabbitmq policy (#19073)
Add check for all policy fields (name, apply_to, pattern, tags,
priority) to have correct changed state. Previosly changed state was
based on policy name only.

* Add support for rabbitmq 3.7
* Fix exec args for rabbitmqctl status
* Add changelog and fix description for Ansible 2.9
2019-05-28 15:06:06 -04:00
Tyler Hartley
1d22909f7c Make second group match of ufw status output optional (#56678)
* Make second group match of ufw status output optional

Fixes #56674

* Fix comparison logic.

* Add changelog fragment
2019-05-28 20:54:11 +02:00
Felix Fontein
86928a5f74
docker_image: fix module failing when build option is used without specifying path (#56940)
* Fix module failing when build option is used without specifying path.

* Add changelog.
2019-05-28 20:48:08 +02:00
Felix Fontein
56e2d48612
docker_image: fix default handling of old docker-build options nocache and rm (#56610)
* Fix usage of nocache parameter.

* Fix defaults.

* Add changelog.
2019-05-28 20:47:31 +02:00
Nathaniel Case
1b66a13186
Fix flow in eos_l2_interface (#57059)
* Also fix test debug labels
2019-05-28 14:06:57 -04:00
Matt Williams
cf00883c9d Return results even when the cache is disabled (#55505)
* Return results even when the cache is disabled

By default the cache is disabled and so the results of the API call
are not placed in there for the return statement to fetch.

* Always update self._cache to return
2019-05-28 13:44:00 -04:00
The Magician
a837cc5694 Bug fixes for GCP modules (#55976) 2019-05-28 13:43:19 -04:00
The Magician
713ac29054 Bug fixes for GCP modules (#56689) 2019-05-28 13:42:12 -04:00
The Magician
0ff62fd5c4 Bug fixes for GCP modules (#56764) 2019-05-28 13:41:51 -04:00
The Magician
70ac35da3e Bug fixes for GCP modules (#56765) 2019-05-28 13:41:36 -04:00
The Magician
2220b9c851 Bug fixes for GCP modules (#56766) 2019-05-28 13:41:19 -04:00
Paul Belanger
532de89b44
Fix exception with load_provider function (#56959)
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>
2019-05-28 12:19:34 -04:00
Brian Coca
1a893a48a3
Allow finer grained control for dupe YAML keys (#56933)
* Allow finer grained control for dupe YAML keys

  fixes #16903

* expand option to handle errors

* remove clog for previous version of toggle

* added missing parens

* fix typoe
2019-05-28 11:57:16 -04:00
Brian Coca
615db8e6f4
clarify package facts errors and warnings (#56060)
* clarify package facts errors and warnings

  fixes #56056
2019-05-28 10:01:47 -04:00
Ankur Gupta
a40dc1174e Add support to start a vm and put it on hold in one_vm (#56841)
* 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
2019-05-28 07:58:13 -04:00
Felix Fontein
61b48778a7
Rename _facts -> _info (#57028) 2019-05-28 13:43:04 +02:00
Felix Fontein
d8dcd20294 docker_container: fix container creation with networks_cli_compatible=yes (#56687)
* Fix behavior.

* Add changelog.

* Add simple test to prevent #56620.
2019-05-28 03:19:52 -04:00
Andrey Klychkov
baac1df935 New module mysql_info - Gather information about MySQL servers (#55434)
* New module mysql_info: collect info about MySQL server instance

* mysql_info - CI tests

* mysql_info: fixes

* mysql_info: fixes Decimal

* mysql_info: fixes Decimal converters.py

* mysql_info: fixed err conn message and check_mode

* mysql_info: added decimal.Decimal to lib/ansible/parsing/ajson.py

* mysql_info: convert Decimal to float

* mysql_info: fix

* mysql_info: fix

* mysql_info: returned the args list as it was

* mysql_info: fix typo

* mysql_info: fixes

* mysql_info: removed aliases for login_db

* mysql_info: changed RETURN condition info

* mysql_info: fixed doc

* mysql_info: fixed role's parsing

* mysql_info: fixed role's parsing

* mysql_info: fixes

* mysql_info: fixed integration tests
2019-05-28 09:10:12 +02:00
ShachafGoldstein
f137527201 $result.reboot_required = $feature_result.RestartNeeded (#56419)
* $result.reboot_required = $feature_result.RestartNeeded

* Update relevent PSLint ignores

* CI Problem with pslint and ignore.txt
2019-05-28 01:21:56 -04:00
Abhijeet Kasurde
c6ba5eb8a0 Remove unnecessary pass (#56992)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2019-05-28 12:43:22 +08:00
Yury V. Zaytsev
fcfc122205 route53_facts: add check mode support (#56900)
* 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>
2019-05-27 23:44:55 +02:00
Felix Fontein
7a0af34ba9
First batch _facts -> _info rename. (#56822) 2019-05-27 18:17:42 +02:00
Robert Bridge
0d75e2659e GH-56902 Copy to new list from dict.items() return
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
2019-05-27 10:16:17 -04:00
Andrey Klychkov
a946d5d8ce postgresql_owner: added docstrings (#57010) 2019-05-27 08:04:58 -04:00
Martin Ouimet
398f4b8233 Added the 'show commit config diff' output available from the IOSXR device (#54875) 2019-05-27 17:30:14 +05:30
Andrey Klychkov
c0fd1bef7c postgresql_info: removed deprecated checks, added doc strings (#57005) 2019-05-27 07:13:22 -04:00
rajaspachipulusu17
19a78bdc7b Pluribus Networks vrouter bgp module with unit test cases (#56434)
* Pluribus Networks vrouter bgp module with unit test cases
* Sanity fixes
2019-05-27 11:53:57 +05:30
Lukas Kämmerling
7f08de6b6c hcloud_volume attach step should be idempotent (#56906) 2019-05-27 07:48:48 +02:00
Klaus Frank
8f89d1d3da VMware: Fix python 3 incompatibility (#54123)
Add Python2 and Python3 compatible `string.translate` for hostname customzation.

Fixes: #54118
2019-05-27 11:10:49 +05:30
Martin Adler
d5ab712fad DNS Made Easy fix locale for date string (#44624) 2019-05-26 23:49:17 +02:00