Commit graph

36315 commits

Author SHA1 Message Date
Toshio Kuratomi
0e5c66ae72 Fixes for multiline doc descriotions breaking rst formatting
* strip whitespace to preserve indent level
* Make sure to indent subsequent lines of indentation

(cherry picked from commit 6ddc64bc7c)
2018-04-19 11:38:14 -07:00
Brian Coca
0d83a0a888 make aef test more predictable
revert "Disable any_errors_fatal test."
This reverts commit 56189cc312.

fixes #38407

(cherry picked from commit 3c996d0f74)
2018-04-19 10:35:23 -07:00
Sloane Hertel
cb5083b679 [cloud] Add AWSRetry to ec2_vpc_net and ec2_vpc_dhcp_option to stabilize return values (#36264) (#38975)
Fixes #36063, fixes #37323, fixes #36078 (#37354)

* Add AWSRetry when describing VPCs to help stabilize integration tests

* Add retry on create_tags because it is possible to reach this API call before the VPC is finished creating

* Increase delay and tries for ec2_vpc_net backoff

* Wait for DHCP option to be created in ec2_vpc_dhcp_option

* Wait for all modifications to the VPC

* Use the vpc_available waiter because is uses Filters

* Optimize retries to only occur if the functionality is available

Cherry-from:
- 16f8a993a0
- e9c57e732f
2018-04-19 09:28:57 -04:00
Will Thames
4d95f467f5 elb_target_group: use port parameter as default for target port (#38578) (#38992)
The docs suggest that `port` parameter is the default port upon
which targets listen. As such, a target need only provide a `Port`
key to override the default.

(cherry picked from commit dc09ddfbd5)
2018-04-19 09:25:24 -04:00
Will Thames
2b985137d7 [AWS cloudfront_distribution] Update minimum protocol versions (#38644) (#38990)
As per docs, the current set of values is

```
'SSLv3'|'TLSv1'|'TLSv1_2016'|'TLSv1.1_2016'|'TLSv1.2_2018'
```

Fixes #38642

(cherry picked from commit 6b970348b1)
2018-04-19 09:24:17 -04:00
Brian Coca
16f48b539f ensure cli dir exists before saving files to it
(cherry picked from commit 28015d8ae9)
2018-04-18 20:53:40 -07:00
Matt Davis
ed473d792b New release v2.5.1 2018-04-18 16:48:39 -07:00
Dag Wieers
3d0c00091d Clean up Grafana docs a bit (#37516)
* Clean up Grafana docs a bit

But more is needed, default values, missing choices, proper
descriptions, actual sentences :-)

* Remove validate-modules entries

(cherry picked from commit 51662acc6c)
2018-04-18 10:14:02 -07:00
Brian Coca
2f64d6fcfb Ensure non ansilbe exceptions keep tracebacks (#37523)
(cherry picked from commit d9430b79f9)
2018-04-18 10:13:29 -07:00
Brian Coca
20430f901e show changed in online
(cherry picked from commit 32cf79c044)
2018-04-18 10:13:04 -07:00
Andrew Gaffney
3362ad16b1 Load plugin config defs on first load only (fixes #37553) (#37584)
(cherry picked from commit 0d0bdbec62)
2018-04-18 10:11:36 -07:00
Jonas Meurer
5ea8fa4052 Update porting_guide_2.5.rst (#37927)
The example regarding `include_*` is a bit unclear. First it seems like the v2.4 and v2.5 examples are the same. So I attempted to make the relevant change in the examples more obvious.

 label: docsite_pr
(cherry picked from commit 55fd3d62fb)
2018-04-18 10:08:58 -07:00
Brian Coca
5e8aeddc85 remove unused optoins from inventory cli
fixes #31929

(cherry picked from commit 1b9879ccbf)
2018-04-18 10:08:58 -07:00
Toshio Kuratomi
d4be7f772a Some more fixes for the docs :ref: disambiguation
The big one is that we needed to set plugin_type when we processed the by_support template.

Also added to list_of_CATEGORY_plugins page (which might not be used)
and corrected a place where I did module_name instead of name_module

(cherry picked from commit 8cdd75a09f)
2018-04-18 10:06:44 -07:00
Brian Coca
07bb0407ad documented actual precedence (#38009)
fixes #22025
(cherry picked from commit 5ad13d66aa)
2018-04-18 10:02:37 -07:00
Christian Fetzer
529d778015 docs: Document disabling diff on task level (#37998)
* docs: Document disabling diff on task level

Tasks that deal with secrets may leak sensitive information when
running in Check Mode. This change updates the documentation explaining
that the diff can be deactivated on task level.

The feature was requested in #14860 and got introduced in Ansible 2.4
with #28581.

* Updated for clarity

(cherry picked from commit 9cca9a9c10)
2018-04-18 10:01:55 -07:00
Pilou
5fc9f3d219 module_common: handle None value for templar (#36651)
* module_common: set required parameter templar

Fix the following error (related to b455901):

  $ ./hacking/test-module -m ./lib/ansible/modules/system/ping.py -I ansible_python_interpreter=/usr/bin/python
  Traceback (most recent call last):
    File "./hacking/test-module", line 268, in <module>
      main()
    File "./hacking/test-module", line 249, in main
      (modfile, modname, module_style) = boilerplate_module(options.module_path, options.module_args, interpreters, options.check, options.filename)
    File "./hacking/test-module", line 152, in boilerplate_module
      task_vars=task_vars
    File "ansible/lib/ansible/executor/module_common.py", line 910, in modify_module
      environment=environment)
    File "ansible/lib/ansible/executor/module_common.py", line 736, in _find_module_utils
      shebang, interpreter = _get_shebang(u'/usr/bin/python', task_vars, templar)
    File "ansible/lib/ansible/executor/module_common.py", line 452, in _get_shebang
      interpreter = templar.template(task_vars[interpreter_config].strip())
  AttributeError: 'NoneType' object has no attribute 'template'

* module_common.modify_module: templar is required

(cherry picked from commit 7908f78fa6)
2018-04-18 10:01:31 -07:00
Jim Gu
8473765ae6 yaml callback fails on python3
When the URI module returns complex JSON objects, the YAML callback
fails while trying to represent these objects.  The problem arises
because the filter method returns an iterator in Python 3, rather than a
str object.  Therefore, the str method expandtabs() is not available,
and the callback fails with the following error:

[WARNING]: Failure using method (v2_runner_on_failed) in callback plugin (<ansible.plugins.callback.yaml.CallbackModule object at 0x7f7c7ed8aa20>): 'filter' object has no attribute 'expandtabs'

Issue can be replicated by running this playbook:

- hosts: localhost
  gather_facts: false
  tasks:
    - uri:
        url: https://jsonplaceholder.typicode.com/posts

ansible-playbook tmp.yml -v

(cherry picked from commit 5839f07e0f)
2018-04-18 10:00:44 -07:00
Artem Tiumentcev
b37facb234 fix set options in callbacks for foreman
(cherry picked from commit 082b03c829)
2018-04-18 10:00:07 -07:00
Brian Coca
d31d84cfa3 avoid caching invetnory sources in loader (#38242)
* fix inventory plugin source caching

 - avoid caching invetnory sources in loader in base
 - same fix for yaml plugin
 - idem for 'auto' plugin

fixes #37162

* fix mock dataloader func sig

(cherry picked from commit 886c4edfb9)
2018-04-18 09:59:35 -07:00
Lutz Reinhardt
a3798d9b62 fix bug in modules/system/user.py (#37552)
for freebsd tool "pw" use date not days in "modify_user"
(cherry picked from commit d512bed495)
2018-04-18 09:57:56 -07:00
Bill Nottingham
923015d9d7 Set raw=True when reading passwords from ConfigParser files. (#35582)
* Set `raw=True` when reading passwords from ConfigParser files.

The assumption is that no one is actually doing interpolation on the
password value, even if they may for other configuration values, and
passwords are far more likely to contain '%'.

* Add vmware_inventory as well.

(cherry picked from commit 15b6ec66bb)
2018-04-18 09:41:16 -07:00
Brian Coca
0852ea6dc0 clarify os x password with user module (#38344)
also removed pointer to non existing example

fixes #36427
(cherry picked from commit f630d420c6)
2018-04-18 09:40:44 -07:00
AlanCoding
dfbba6e75b Reduce recursion within group methods
This offers an optimization that allows loading larger
inventories of various structure by improving the
scaling laws involved for adding hosts and groups.

The primary speed benefit is the elimination of duplicate
recusion from traversing converging paths.

(cherry picked from commit 153c9bd539)
2018-04-18 09:32:30 -07:00
Brian Coca
cf1cb61efb clarifying docs with first_found (#36951)
better examlpes as this was never really a task loop, but contained inside the lookup itself
(cherry picked from commit 42d15671d0)
2018-04-18 09:31:30 -07:00
Brian Coca
00848dff17 made missing cli tools non fatal (#37194)
* made missing cli tools non fatal

* remove bare exceptions

these shoudl not be there as they can prevent 'wanted' exits

(cherry picked from commit 0c2e7fd841)
2018-04-18 09:24:58 -07:00
Toshio Kuratomi
f670602448 Fix places in docs that refer to modules without namespace
We've namespaced all plugin docs.  Change the docs to reflect that

(cherry picked from commit 9faf7b949e)
2018-04-18 08:48:41 -07:00
Martin Krizek
751ae4f4a9 playbooks_variables.rst: fix facts code-block (#38520)
(cherry picked from commit 5297eac46d)
2018-04-18 08:44:27 -07:00
Brian Coca
145f42eba3 fix displaying group vars in graph
(cherry picked from commit 265d838ec9)
2018-04-18 08:34:24 -07:00
Toshio Kuratomi
003c52f1ef Modules that have a link to their own deprecated section need to use a different link syntax (#38697)
The :ref: syntax is for linking to targets which are defined for the
whole document tree.  `link`_ is for linking to targets which are inside
of the document.  We want the latter for deprecated sections because
otherwise we'd have to create namespaced link targets for them.

Also fix expansion of version a deprecated module will be removed in
(cherry picked from commit 25523666ce)
2018-04-18 08:28:59 -07:00
Chris Houseknecht
61e3f32f81 Auth method for the k8s lookup plugin now matches other modules (#37533) (#37618) 2018-04-18 08:08:15 -07:00
Trishna Guha
456fe2add1
nxos bugfixes cherry-pick (#38950)
* fix nxos_ntp_options (#38695)

(cherry picked from commit 1d975bdc93)

* fix ntp_auth issues (#38824)

(cherry picked from commit a372142434)

* update nxos changelog

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-04-18 09:59:39 -04:00
Abhijeet Kasurde
9a7da8d3da
add instanceUuid (also called PersistentId) in vmware utils (#38870)
(cherry picked from commit 0cdba9ff70)
2018-04-18 17:41:15 +05:30
Jordan Borean
0fede2ba60
Tolerate win line endings on module load 2.5 (#38919)
* Tolerate win line endings on windows module_util load (#37291)

* tolerate windows line endings when loading windows module utils.  Helpful for old custom windows modules.

* add test modules to demonstrate win line ending module load behaviour.

* attempt to fix sanity check failures

* pep8 fix

* explict skip of test modules from shebang check (core modules must still have expected unix style line endings)

* switch to rstrip() following core team meeting feedback

(cherry picked from commit ad94d03ba1)

* Added changelog fragment

* Added ignore rules to older sanity tests

* Removed test files due to old shebang not being possible without bigger change
2018-04-18 15:25:18 +10:00
Jordan Borean
4b55ecc825
Update win_certificate_store.py (#38860) (#38927)
* Update win_certificate_store.py

Improvements to describe the different destination stores.

+label: docsite_pr

* Update win_certificate_store.py

Whole line needs to be quoted -- lingfish YAML fail.

(cherry picked from commit d684c51815)
2018-04-18 14:31:09 +10:00
Matt Clay
8606fa0431 Update httptester container reference.
(cherry picked from commit 35748e5228)
2018-04-17 21:26:02 -07:00
scottb
893807bfc9 [WIP] disambiguating autogenerated module docs attempted fix of #38439. (#38890)
Disambiguates autogenerated module docs - fixes #38439.

(cherry picked from commit c97e508806)
2018-04-17 18:49:27 -07:00
Toshio Kuratomi
4091ab479f Add alias's as a :ref: target for modules
This is especially important for deprecated modules as we want to link
to those in porting guides and such.

(cherry picked from commit 8f1b5fc47b)
2018-04-17 18:49:20 -07:00
Jordan Borean
10aa5a37aa
win_regedit: backport 2.5 stabilise tests (#38918)
* win_regedit: stabilise tests (#38912)

(cherry picked from commit 77ef4802f0)

* Added changelog fragment
2018-04-18 08:45:00 +10:00
Jordan Borean
9178def456
Fix typo in windows_faq.rst (#38864) (#38916)
Fix typo in `python-pip` packet name.
+label: docsite_pr

(cherry picked from commit 92f4065157)
2018-04-18 08:06:42 +10:00
Matt Clay
2b73a5b69f Restore docker_secret test on RHEL.
(cherry picked from commit 57f1298074)
2018-04-17 13:57:05 -07:00
Matt Clay
938625add7 Disable failing fortios_* tests. 2018-04-17 11:55:41 -07:00
Sviatoslav Sydorenko
867bc8967e
Upgrade PYPI badge to point to new Warehouse site
It should become default quite soon:
https://github.com/pypa/warehouse/milestone/1
2018-04-17 16:03:11 +02:00
Toshio Kuratomi
ae79eef0b2 Add changelog entry for grafana base64 port
(cherry picked from commit f5cc4acc53)
2018-04-17 06:52:56 -07:00
Rémy Léone
24c1e2ed0a Fix deprecated warnings
(cherry picked from commit 98fb47b061)
2018-04-17 06:52:50 -07:00
John R Barker
f5befa5ab4
Correct formatting (#38874) (#38877)
(cherry picked from commit 3d3781db57)
2018-04-17 13:22:43 +01:00
John R Barker
507423f111
issue:38321 fix onyx_config module failed while using python = 3.5 (#38343) (#38869)
* issue:38321 fix onyx_config module failed while using python = 3.5 (#38343)

(cherry picked from commit 0d79268a6d)

* changelog
2018-04-17 13:16:03 +01:00
Abhijeet Kasurde
bb50c65769
VMware: handle permission denied while reading facts (#38868)
This fix adds exception handling which is raised when user
does not have correct set of permissions/privileges to read virtual machine
facts especially host system configuration.

Fixes: #37056

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
(cherry picked from commit efc3f4f824)
2018-04-17 16:20:46 +05:30
Abhijeet Kasurde
5f8758d6a3
Use correct esxi host variable in vmware_cfg_backup
Fixed bug where hostname could not be found and minor documentation changes.

(cherry picked from commit 8f5320435f)
2018-04-17 15:20:09 +05:30
Abhijeet Kasurde
d9436f18f5
VMware: correct documentation for datacenter
This fixes documentation related to datacenter in vmware_guest_find
module.

Fixes: #38290

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
(cherry picked from commit 2367130ba3)
2018-04-17 15:07:05 +05:30