Commit Graph

40400 Commits (e31620e9db8562ebbd2bf567c67678f2b1e274e0)
 

Author SHA1 Message Date
Sloane Hertel 5769d46aa3 use composed vars in constructed groups (#53152)
* changelog

* combine provided variables and host vars inside of constructing groups to take into account composed variables

let composed variables "win"

* fix whitespace

* Allow user to control hash behavior

(cherry picked from commit 4172d68dc3)
6 years ago
Felix Fontein 2773e215f7 [2.7] docker_swarm: removing nodes requires docker >= 2.4.0 (#53592)
* Removing a swarm node does not work with docker-py < 2.4.0, since it calls client.inspect_node(). (#53565)

For the same reason, docker_node requires docker >= 2.4.0.

(cherry picked from commit c75da35595)

* Reconstructing a change from devel which is required to make usage detection work this way.
6 years ago
Jason Witkowski b84d9a8365 apply node_id parameter to swarm node removal (#53503)
(cherry picked from commit be39e757e3)
6 years ago
Matt Martz 07e4ae0806 [stable-2.7] Allow dict2items to work with hostvars (#53538).
(cherry picked from commit 414440e323)

Co-authored-by: Matt Martz <matt@sivel.net>
6 years ago
Brian Coca c93bfe9931 allow nontype configdata (#53365)
(cherry picked from commit 90bcff3d92)
6 years ago
Jakob Ackermann 3944f51677 [docker_image] fix the changed state for tagging and pushing (#53451)
* [docker_image] fix the changed state for tagging and pushing

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [docker_image] add tests for (force) tagging and force pushing

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [docker_image] add a news fragment for the fixed force tag/push behavior

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>
(cherry picked from commit 13ab9a61a8)
6 years ago
Timo Runge a32e8c42b9 Fix for "AttributeError: 'module' object has no attribute 'cursors'" (#49191) (#53445)
* Fix for "AttributeError: 'module' object has no attribute 'cursors'" (#49191) (#1)

* Fix for "AttributeError: 'module' object has no attribute 'cursors'" (#49191)

* Adding changelog fragment for issue #49191 and the following PR.

* Update lib/ansible/module_utils/mysql.py

Co-Authored-By: timorunge <timorunge@users.noreply.github.com>
(cherry picked from commit b45b599433)
6 years ago
Timo Runge 7e83675227 module_utils/mysql: Fixing unexpected keyword argument 'cursorclass' error after migratio… (#47809)
* Fixing unexpected keyword argument 'cursorclass' error after migration from MySQLdb to PyMySQL

* Adoptions for mysql.py as suggested by felixfontein.

* Adding changelog fragment.

(cherry picked from commit 47190088b4)
6 years ago
Jordan Borean b658139d63 test: fix get_url issues in CI for Ubuntu 14.04
(cherry picked from commit 0f2041abbd)
6 years ago
S edd7e53b8b Fixed win_file crash with hidden files (#52584)
* Fixed crash with hidden files

added "-force" parameter on "Get-Item" cmdlet. this is needed to get file info if the file is "hidden" 
without this option modules like win_file, win_template, win_copy crashes on hidden files. this is because with "test-path" it sees that the file exists, but "get-item" can't get the file info. 
for more information on "-force option": https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.management/get-item

* Add changelog and integration tests

* fix tests for older Windows versions

(cherry picked from commit 3bc474bf99)
6 years ago
Jordan Borean e0294275d7 win_domain: fix issue when running without credential delegation (#53480)
* win_domain: fix issue when running without credential delegation

* Add check for reboot is required to complete role e install

* Fix changelog sanity issue

* removed meta file accidentally committed

(cherry picked from commit 008db85d44)
6 years ago
Felix Fontein c4748fd011 openssl_csr: improve subject validation (#53198)
* Improve subject field validation.

* Add country name idempotency test.

* Add failed country name test.

* Add changelog.

(cherry picked from commit b2e992cecd)
6 years ago
Felix Fontein 9135dbd820 Trying to work around spurious test failures. (#53472)
(cherry picked from commit e4f2e15b96)
6 years ago
Sandra McCann 82ccbd939c Clarify that do until loops are unsupported on include tasks (#49581) (#53628)
(cherry picked from commit 0d7e95b4db)
6 years ago
Felix Fontein 63b2794607 Warn user to send a password if the privatekey is password protected (#53360) (#53527)
* Warn user to send a password if the privatekey is password protected on openssl_cert and openssl_csr docs 

Co-Authored-By: johnwesley <johnwesley@users.noreply.github.com>
6 years ago
Sloane Hertel 96aa6babc1 Mark ec2_vpc_vgw as disabled to avoid hitting the resource limit (#53082)
* Mark ec2_vpc_vgw as disabled to avoid hitting the resource limit (#53082)

(cherry picked from commit c4d0c58c5a)
6 years ago
Felix Fontein 3380defd67 [2.7] docker_swarm_service: rename return variable to swarm_service (#53408)
* docker_swarm_service: rename return variable to swarm_service (#53229)

* Rename return variable to swarm_service.

* Add changelog.

* Add that old name will stay in Ansible 2.7.x.

(cherry picked from commit 61abbfc269)

* Keep old variable for backwards compatibility.
6 years ago
Felix Fontein 3eccd83891 openssl_csr: improve invalid SAN error messages (#53201)
* Improve invalid SAN error messages.

* Add changelog.

(cherry picked from commit 628326b879)
6 years ago
Felix Fontein 3d351c5367 2.7 way to make sure no SANs are there. 6 years ago
Felix Fontein 94b5a03b0e openssl_certificate: make sure extensions are present when they are queried by assertonly (#53207)
* Make sure extensions are present when they are queried by assertonly provider.

* Add changelog.

(cherry picked from commit 6249bb8ea4)
6 years ago
Jordan Borean ba261abe29 re-add EAP to Stop for older branch 6 years ago
Jordan Borean 8bb830c1b4 win_chocolatey_source - fix state=disabled with no source (#53097)
(cherry picked from commit be7768efc7)
6 years ago
Jordan Borean bfe072c9dc winrm - try and recover from a send input failure (#53187)
(cherry picked from commit ae24bbff4a)
6 years ago
Felix Fontein ed12e93f73 [stable-2.7] Python 2: accept both long and int for type=int (module options) (#53289)
* Added unit test.
(cherry picked from commit 07fcb60d55)

Co-authored-by: Felix Fontein <felix@fontein.de>
6 years ago
Sandra McCann 2f0b727acf backport correct examples (#53411) 6 years ago
Felix Fontein 2f91d399ec [2.7] docker_swarm_service: don't crash when publish isn't specified (#53262)
* Don't crash when publish isn't specified.

* Add changelog.

* Add validation code.

* Use generic supertype of dict.
6 years ago
Felix Fontein 72f4d1b22b Make clear which option is used by which provider. (#53208)
(cherry picked from commit 6b948ab031)
6 years ago
Brian Coca 03ceec9c78 properly convert inputs to handle bytes/unicode (#53072) (#53124)
* properly convert inputs to handle bytes/unicode (#53072)

* properly convert inputs to handle bytes/unicode

  fixes #52186

* Update changelogs/fragments/nmap_bytes_fix.yml

Co-Authored-By: bcoca <bcoca@users.noreply.github.com>
(cherry picked from commit 55dc63be3a)

* updated as per fb

* spacer
6 years ago
Felix Fontein 5aabb5ea02 docker_swarm: support older docker-py versions (#53129)
* Decreasing docker_swarm requirements.

* Fixing docker-py / docker API version requirements, and some comments.

* Add changelog.

* Only send parameters specified by user to docker daemon.

* Extend labels test: not specifying == keep labels.

* Bump minimally required docker-py version for docker_node and docker_node_facts to 2.4.0.

* Prevent crashing when publish or healthcheck is not provided.

* Similarly to docker_swarm tests, only execute docker_node tests on real VMs and restart docker daemon when tests are done.

(cherry picked from commit 8e26c2dfbe)
6 years ago
Felix Fontein 122e73d062 [2.7] docker_swarm_service: fix problem with UpdateConfig on certain docker daemons (#53224)
* Avoid KeyError when UpdateConfig isn't returned.

* Add changelog.
6 years ago
Felix Fontein 597db1dc28 [2.7] openssl_certificate, fixed has_expired to check the cert expiration date (#53203)
* Type error in openssl_certificate (#47508)

* Fixed #47505: Type error in openssl_certificate
* Use to_bytes instead of str.encode in SelfSignedCertificate. Updates #47508
* Use to_bytes instead of str.encode in OwnCACertificate
* Added integration tests for openssl_certificate: selfsigned_not_before/after and ownca_not_before/after

(cherry picked from commit 5b1c68579d)

* openssl_certificate, fixed has_expired to check the cert expiration date (#53168)

(cherry picked from commit d5d92e4a70)

* Use fixed timestamp in past instead of relative time (relative times are a feature of devel).

* Add changelog for #47508.
6 years ago
Chris Adams 59beb460d8 docs: SAN prefixes are required for openssl_csr (#53144)
The openssl_csr docs use “should” where (at least following IETF nomenclature) “must” would be more accurate.

See #53141 

+label: docsite_pr

(cherry picked from commit 14d4a4fc3b)
6 years ago
s-hertel bded9a1d65 If the private_ip has been provided for the new network interface it shouldn't also be added to top level parameters for run_instances
changelog

(cherry picked from commit d16ec175fc)
6 years ago
Tuan Anh Hoang-Vu 0b453abfa4 [backport 2.7] Fixed lvol ValueError with float size. (#52836)
* Fixed lvol ValueError with float size.

(cherry picked from commit 85bd54dfa7)

* Fixed lvol ValueError with float size.

(cherry picked from commit ecdd835b6c)

* Initialized locale using system default.
Changed size validation from float() to locale.atof().

(cherry picked from commit d187b95929)

* Added changelog fragment.

(cherry picked from commit d1f6b1220c)

* Used C locale instead of relying on system locale.

(cherry picked from commit 90b3d96869)
6 years ago
Sam Doran d44f80cb92 [stable-2.7] Modify the correct variable when setting available hashing algorithms (#52994)
* Revert "use list instead of tuple and remove md5 on ValueError (#51357)" c459f040da.
* Modify the correct variable when determining available hashing algorithms.
(cherry picked from commit 23a6b88dd2)

Co-authored-by: Sam Doran <sdoran@redhat.com>
6 years ago
Tony Finch 9c7d36ccb5 get_url: return no change in check mode when checksum matches
Signed-off-by: Tony Finch <dot@dotat.at>
6 years ago
Pablo Piaggio 5d4a777d16 Backport/2.7/51853 (#53153)
* Add support for macro contexts that have colons (#51853)

Currently when used with macro contexts that have a colon inside, 
macro_name gets truncated. A common case is contexts that represent a 
Windows drive. Examples:

  - 'C_DRIVE_THRESHOLD: "C:"'
  - 'C_DRIVE_THRESHOLD: "D:"'

This happens because line 189 assumes there are only one colon in 
macro_name, and thus two substrings to join.

To solve this, it is necessary considering that macro_name could have 
more that one colon. After the split, the first element is the proper 
Zabbix macro name. Then, the solution is joining all the remaining 
substrings after that.

This is backwards compatible in the case macro_name have only one colon.

(cherry picked from commit d1d4f4bd27)

* Add support for macro contexts that have colons

Currently when used with macro contexts that have a colon inside,
macro_name gets truncated. A common case is contexts that represent a
Windows drive. Examples:

  - 'C_DRIVE_THRESHOLD: "C:"'
  - 'C_DRIVE_THRESHOLD: "D:"'

This happens because line 189 assumes there are only one colon in
macro_name, and thus two substrings to join.

To solve this, it is necessary considering that macro_name could have
more that one colon. After the split, the first element is the proper
Zabbix macro name. Then, the solution is joining all the remaining
substrings after that.

This is backwards compatible in the case macro_name have only one colon.
6 years ago
Piotr Wojciechowski 9e40404d9a Documentation update for labels operations on swarm/node (#53083)
* Update lib/ansible/modules/cloud/docker/docker_node.py
* Update lib/ansible/modules/cloud/docker/docker_swarm.py

Co-Authored-By: WojciechowskiPiotr <23406016+WojciechowskiPiotr@users.noreply.github.com>
(cherry picked from commit ec4cf26d60)
6 years ago
Felix Fontein 8b9c96aad5 Diff feature is only available in devel. 6 years ago
Felix Fontein 25ca40de88 docker_swarm: more integration tests (#53035)
* Add more tests.

* Added tests for CA options.

* Don't run in docker-in-docker situations where docker daemon becoming instable is really dangerous. Also, restart docker daemon after tests.

* Only run CA tests when openssl_certificate can be run (which is not the case for RHEL7, see #34054).

* Add comment on why docker-based CI runs are skipped.

(cherry picked from commit 04bfec9dfe)
6 years ago
Felix Fontein 05f7fbc93a docker_swarm: fix ca_force_rotate idempotency (#53039)
* Fix ca_force_rotate idempotency.

* Add changelog.

(cherry picked from commit dec97381bc)
6 years ago
Felix Fontein c4144398bb Fix force when state==present. (#53003)
(cherry picked from commit 76e0e0080b)
6 years ago
Felix Fontein 7c500a4002 docker_swarm: extend tests (part I) (#53005)
* Restructure tests.

* Allow tests to work when ansible_default_ipv4.address is undefined.

(cherry picked from commit e017d94766)
6 years ago
Felix Fontein 2ee64fd507 docker_swarm: fix idempotency (#52976)
* Improve idempotency checking: only consider parameters which are part of the generated spec.

* Properly handle rotate_worker_token and rotate_manager_token.

(cherry picked from commit 42ae6cdb95)
6 years ago
Felix Fontein aed59e5695 docker_swarm: make labels work with older docker daemon versions (#52895)
* Make labels work with older docker daemon versions.

* Fix idempotence detection.

* Add changelog.

(cherry picked from commit a1ec307d43)
6 years ago
Felix Fontein 7a9e7daf44 Improve documentation on remote_addrs. (#52893)
(cherry picked from commit 3c39fe5871)
6 years ago
Felix Fontein 23d9efc1f3 docker_swarm: hopefully fix debug CI problems, and fix check mode (#52825)
* Let's see some debug output.

* Also check LocalNodeState.

* Improve tests.

* Actually implement check mode.

* Add changelog.

* Add pretty-printing and more output.

(cherry picked from commit 81d58cfef6)
6 years ago
Wojciech Sciesinski 8ae9f99979 Don't run integration tests for OS'es older than Windows 2016 (#53057) 6 years ago
Brian Coca 6bd7ef4838 Ensure play order is obeyed (#49897)
* Ensure play order is obeyed

 it was being ignored depending on other options
 also added tests for each order (except shuffle) both serial and not
 fixes #49846


(cherry picked from commit cfba6dfe91)
6 years ago
Mario Lenz 2aa96cdec5 [Backport 2.7] VMware: Fix KeyError in vmware_host_config_manager 6 years ago