Commit graph

3726 commits

Author SHA1 Message Date
Alex Stephen
650c3c5df3
doc fragment needs proper types (#67545) 2020-02-18 16:40:00 -05:00
Sloane Hertel
ed6a6aca25
Allow botocore configuration for aws modules (#55217)
* Allow botocore configuration to be configurable for boto3 modules

* Allow modification of the boto user agent

* play nicely with modules that might be modifying config

* changelog
2020-02-18 13:12:10 -05:00
Abhijeet Kasurde
70b9bdbce6
Fix links in Postgresql modules (#67511)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2020-02-18 13:18:16 +05:30
Abhijeet Kasurde
7dcf32294b
Update URLs in documentation (#67376)
Partially fixes: #67357

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2020-02-18 09:00:30 +05:30
Lukas Kämmerling
62cc120dce
Add support for networks to hcloud inventory (#67453) 2020-02-17 13:39:37 +00:00
Daniel Sternig
11483921f2
Added additional error handling inside the hcloud.py inventory plugin… (#66381)
* Added additional error handling inside the hcloud.py inventory plugin. Otherwise, errors may happen, if the HCloud API is not able to correctly identify the server image.

* Corrected the previous commit to not check for None on variables that are always set. Additionally, used image.description if image.name was not set, instead of the previously added default string.
2020-02-15 11:09:18 -05:00
Mads Jensen
f978b6c789
Use https for Ansible Slack icon. (#65625) 2020-02-15 14:53:18 +00:00
Tomer Brisker
a4f5c2e993
Post reports to newer Foreman API endpoint (#64955)
The `/api/v2/reports` endpoint has been deprecated a long time ago and should
no longer be used. This changes to callback to use the correct API
endpoint and paramerter.
2020-02-15 13:01:27 +00:00
akatch
936bd83614
Fix duplicate log entries (and add item support for failures) (#66098) 2020-02-15 12:48:05 +00:00
ihard
ad2428c176
fix hashi_vault lookup generates warning at LDAP authenticate #52131 (#67251) 2020-02-15 12:46:44 +00:00
Jim Ladd
a5af649a73
foreman: ansible_ssh_host should consider ip, ipv4, ipv6 (#67401) 2020-02-15 10:05:08 +00:00
John McDonough
210e799375
UCS Emulator link to Doc Fragment use cs.co domain (#67434) 2020-02-14 15:20:17 -05:00
Fortinet Core CSE NA
c1d8bdb87a
FortiAnalyzer Network Manager Hotfix (#62919)
* Hotfix for FortiAnalyzer HTTPAPI Plugin in response to connection issues introduced in Ansible 2.9.

* Changed _connect behavior per Mr. Case.

Co-authored-by: Luke Weighall <lweighall@users.noreply.github.com>
Co-authored-by: Nathaniel Case <this.is@nathanielca.se>
2020-02-13 19:36:48 -05:00
Martin Krizek
a2c620819f
Remove a host from a play after meta: end_host (#66851)
* Remove a host from a play after meta: end_host

* Fix changelog
2020-02-13 15:35:00 -05:00
Felix Fontein
11e75b0af2
Fix broken links in crypto, docker and hetzner modules. (#67360) 2020-02-12 16:41:40 -05:00
tchernomax
53e043b5fe
combine filter: fine list handling (option b) (#57894) 2020-02-12 16:40:36 -05:00
Fortinet Core CSE NA
33f136292b
Hotfix for FortiManager Network Connection Plugin (#62534)
* Hotfix for connection manager persistent connection initialization.

* PEP8 Fixes

* First Round of fixes requested by Qualthos.

* Removed _connection check per Mr. Case.

* Somehow the wrong version got sent... should be all good.

Co-authored-by: Luke Weighall <lweighall@users.noreply.github.com>
Co-authored-by: Nathaniel Case <this.is@nathanielca.se>
2020-02-12 14:30:59 -05:00
Felix Fontein
f6815040fd
add_file_common_arguments: fix defaults and tpyes, improve sanity checking (#67243)
* Make validate-modules stop ignore FILE_COMMON_ARGUMENTS.

* Add types to FILE_COMMON_ARGUMENTS and update document fragment to match it.

* Update ignore.txt.

* Add changelog.
2020-02-12 01:44:11 -05:00
Felix Fontein
f725dce936
Clean up FILE_COMMON_ARGUMENTS (#66389)
* Clean up FILE_COMMON_ARGUMENTS.

* postgresql_pg_hba doesn't declare the backup option.

* uri doesn't declare the remote_src option.

* Add documentation.

* maven_artifact seems to use directory_mode, which it doesn't declare.

* Update changelogs/fragments/66389-file-common-arguments.yml
Update docs/docsite/rst/porting_guides/porting_guide_2.10.rst

ci_complete

Co-Authored-By: Jill R <4121322+jillr@users.noreply.github.com>
2020-02-07 18:56:01 -05:00
Allen Smith
fd8eb77cc3
pmrun - quote success command (#66929)
* Recreate the older behavior where the entire success command was quoted

* Use shlex_quote for a correct fix of this

* Add changelog fragment
2020-02-07 12:15:55 -05:00
Dennis Israelsson
68b981ae21
update nmap inventory plugin to not depend on rdns (#56457) 2020-02-05 17:29:59 -05:00
James Cassell
fd954a9c5c
wait_for_connection: also retry interpreter discovery (#67040)
self._discovered_interpreter_key is None unless a previous iteration
has attempted discovery.  In that case, force re-discovery, as the
previous attempt certainly failed.
2020-02-04 11:40:09 -08:00
Brian Scholer
fc7980af9a
Fix UNC path support in the powershell shell plugin (#66604)
* Fix UNC path joining in the powershell shell plugin, add test

* Remove testy bits and a redundant line

* Fix style nits

* Update to use os.ntpath

* Add changelog for #66604
2020-02-04 16:34:11 +10:00
Jordan Borean
6d792838e4
Move url option from util to individual modules (#67068) 2020-02-04 10:43:33 +10:00
Toshio Kuratomi
f5e194cbcd
Move random_mac into its own file (#67000)
* Move random_mac into its own file

This is likely to be the only filter which is not included in
ansible-base.  So it needs to be in its own file.
2020-01-31 14:33:16 -08:00
Petr Mikusek
725bb4d173
Fix typo in shell_windows.py (#66964) 2020-01-31 11:48:28 -05:00
Sam Doran
5112feeace
Make get_bin_path() always raise an exception (#56813)
This makes it behave in a more idiomatic way

* Fix bug in Darwin facts for free memory
    If the vm_stat command is not found, fact gathering would fail with an unhelpful 
    error message. Handle this gracefully and return a default value for free memory.

* Add unit tests
2020-01-30 12:54:25 -05:00
Andrew Klychkov
c9a34ae33e
mysql modules: fix the module's documentation (#66848) 2020-01-30 11:44:47 -05:00
Paul Belanger
adf73d47ec
Remove unused imports from paramiko_ssh connection (#66948)
These were caught by flake8 testing for ansible.netcommon collection.

Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2020-01-30 11:01:34 -05:00
rule88
6a1f82f174
url lookup - add options to match those in urls.py (#64892)
Add 'force_basic_auth' option
By default "force_basic_auth" option is set to False, with this adjustment it is up to the user if it wants to enforce basic authentication.
2020-01-29 16:45:25 -05:00
Joseph Hobbs
72fbbbeb34
Typo correction (#66869)
* Corrected typo in documentation
* Corrected typo in the log statement
2020-01-29 19:46:43 +05:30
Eitan Adler
86663abf37 all: fix all the the duplicate words (#66784) 2020-01-28 14:06:40 -05:00
Geri Jennings
b482857fd3 Update conjur_variable.py (#66763)
Update the link in the Conjur documentation to point to the correct current URL
for information on Conjur machine identity.
2020-01-28 13:15:12 -05:00
Sam Doran
cc2376b782 include_vars - fix stack trace when run ad-hoc with dirs parameter (#66581)
Add integration test

There are a number of other parameters that result in stack traces as well when this module is used ad-hoc. I'm not sure if we're interested in fixing them all since this module isn't meant to be run ad-hoc.
2020-01-28 11:50:34 -05:00
Alex Stephen
cba0feab18 folder support on gcp_compute (#66511)
* folder support on gcp_compute

* fixed issues associated with projects with no vms

* linter fix

* more linter

* linter
2020-01-27 22:37:14 +00:00
Pilou
bbbdc1c25c throttle: fix linear based strategies (#65422)
* throttle tests: fix detection of parallel execution

The test wasn't able to detect if too many workers were running.

On my laptop:
- without this change, the 'throttle' target takes ~20 seconds
- with this change, the 'throttle' target takes ~70 seconds
- 1 second isn't long enough to encounter the issue

* Fix throttle test when strategy is 'free' based

'free' strategy allows multiple tasks to be executed in parallel: use
one 'throttledir' per task.

Use 'linear' strategy with a dedicated play for cleanup/setup tasks

* throttle: reset worker idx before queuing a new task

* TestStrategyBase: define task.throttle

otherwise '1' will be used instead of the default value due to the
following expression being equal to '1':

    int(templar.template(task_mock.throttle))

Co-authored-by: James Cammarata <jimi@sngx.net>
2020-01-24 08:18:08 -06:00
Jiri Tyr
913037731f Update examples in documentation for env lookup plugin (#62662) 2020-01-23 15:27:30 -05:00
Albert Siersema
4a0c875447 Working Cisco IOS macro editing (fixes #55211) (#55220)
* Working Cisco IOS macro editing (fixes #55211)

* Working Cisco IOS macro editing [fixed pylints] (fixes #55211)

* Added integration tests for edit_macro

* Added conditional integration tests for ios_config macro

* Cosmetic fix: when near block for added conditional integration tests for ios_config macro

* Move teardown to always for block
2020-01-23 21:19:15 +05:30
Sam Doran
2b7393141f
reboot - add boot_time_command parameter (#62680)
Allow the built in commands for checking boot time to be overridden. This is mainly for containers and other odd systems where it would add too much complexity to the plugin code to try and discern the correct command to use.
2020-01-21 13:42:32 -05:00
Chris Van Heuveln
7fabb28d22 nxos_gir timeout fixes (#66043)
* nxos_gir timeout fixes

* additional setup/teardown cleanups for sanity test

* Add timeout extension comment to module header

* lint

* rework logic to use action plugin
2020-01-20 12:45:49 +05:30
Adam Miller
077a8b4898 podman - fix rootless container copy no pause (#66583)
Fixes #66263

Signed-off-by: Adam Miller <admiller@redhat.com>
2020-01-17 16:41:10 -05:00
Sam Doran
9b7198d25e
file - change _diff_peek type in argument_spec (#60428)
* Add integration tests
* Handle error in _get_diff_data()
* Change to warning rather than error
* Also change failure to warning in assemble action plugin
2020-01-17 16:02:28 -05:00
Gonéri Le Bouder
cd760782c9 vmware_rest_client: define 'port' parameter (#66506)
Ensure the `vmware_rest_client` based modules accept the `port`
parameter.
2020-01-17 08:11:24 +05:30
Paul Belanger
0fa556f751
Fix flake8 errors related to vyos.vyos collection (#66516)
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2020-01-16 08:22:51 -05:00
jainnikhil30
ea6bc98398 Foreman: support for want_collectionhosts and want_ansible_ssh_host
* Add support for want_collectionhosts and want_ansible_ssh_host in foreman plugin
2020-01-16 14:55:45 +05:30
Evgeni Golov
ee3dcb4d35 use query instead of q in "if files exist" example (#66409)
##### SUMMARY
It's not obvious that `q` is the same as `query` (which is referred to in the name of the task) and using long-names is generally preferred in examples.

##### ISSUE TYPE
- Docs Pull Request

+label: docsite_pr
2020-01-15 14:19:16 -05:00
ad1rie1
9272e3d547 Fix Bug (#64553) 2020-01-14 11:08:38 -05:00
ndclt
d64b49e8a0 Delete linter ignore lines for keycloak modules (#66406)
* linter: auth_client_id is not required, default value

Delete the lines linked to this mistake in ignore.txt.

* doc: state is not required
2020-01-13 10:41:07 +00:00
Felix Fontein
b070fd1630
Fix typo. (#66403) 2020-01-13 07:27:07 +01:00
Ganesh Nalawade
654b9e2754
Add collection support with local for supported network platforms (#66302)
* Add collection support with local for supported network platforms

*  The legacy behavior of network action plugins using persistent
   the framework is to override the connection=local with the actual connection type (network_cli/netconf/httpapi) based
   on the value of transport option in provider.
*  After the actual connection plugin is identified try to load it from
   `ansible.netcommon` collection, if it fails load it from ansible
   core. This is done to work with Ansible 2.10 and also maintain backward compatibility for
   Ansible 2.9 version to ensure it works with network collections.
*  To support this need to pass collection_list value to connection
   plugins. As in case of connection=local it loads `persistent`
   connection within action plugin which in turn invokes `network_cli`
   or `netconf` connection. Similarly `network_cli` connection plugin invokes
   `terminal` and `cliconf plugins and `netconf` connection plugin invokes `netconf`
   `plugins` based on value on `ansible_network_os`.
*  Add deprecation warning for connection=local support and
   provider support for applicable platforms

* Fix CI failures
2020-01-13 09:49:55 +05:30