Commit Graph

715 Commits (stable-2.7)

Author SHA1 Message Date
Jordan Borean e51edbfa1e win_region - fix format issues when using psrp (#55487)
(cherry picked from commit f247c21d23)
6 years ago
Jordan Borean ab725bb86e psrp - Fix raw and script tests for connection plugin (#55357)
* psrp - Fix raw and script tests for connection plugin

* Fix error propagation with raw in psrp

* uncomment test

(cherry picked from commit fdf9df89f5)
6 years ago
Christopher Snyder ad953171eb redhat_subscription: Fix usage of ConfigParser (#54815)
(cherry picked from commit 09f68fc659)
6 years ago
Jordan Borean 8d259f6e64 psrp - fix test_command rc for win_reboot (#55354)
(cherry picked from commit 49655a452d)
6 years ago
Jordan Borean 08c2fb8626 psrp - Fix fetch for large files (#55351)
* psrp - Fix fetch for large files

* Fix typo

(cherry picked from commit 52946c49a4)
6 years ago
Dag Wieers 653e9da228 ACI: Ensure we use native strings for signature (#55161)
* ACI: Ensure we use native strings for signature

* Add changelog fragment
6 years ago
Trishna Guha ca49ae7ba5 nxos_interface DI delay only when operation state check is requested (#55355)
* nxos_interface:DI: delay only when operation state check is requested (#54862)

* nxos_interface:DI: should only use delay when operation state check is requested

There is a 10 second delay that is added for every interface that is changed.
This delay should only occur when a task sets one of the `want` vars.

* /return/continue/

(cherry picked from commit 0fe6bf911a)

* changelog

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
6 years ago
Kevin Breit 1435b6771a meraki_vlan - Remove unnecessary API calls when net_id is specified (#54939)
* Remove unnecessary API calls when net_id is specified

* Remove temp_get_nets commented out code

(cherry picked from commit fb3cc7f687)
6 years ago
Mario Lenz 3604fe8517 backport #55193 to 2.7 6 years ago
Felix Fontein f27481a6e8 docker_container: improve log_options idempotency by converting to string (#54955)
* Warn when log_options values are not strings.

* Add changelog.

* Improve message.

* Improve formatting and formulation of other messages.

* Add test for warning.

* Trying double escaping.

(cherry picked from commit d64b17731d)
6 years ago
Brian Coca bcf0770a04 remove become_plugins ref from backported fix 6 years ago
Jordan Borean fb96c007b5 win_domain - fix for checking for domain on new host (#55195)
(cherry picked from commit 6039ff9a24)
6 years ago
Brian Coca 5d58a7cadb Correct plugin loader context for persistent (#54860)
* Correct plugin loader context for persistent

(cherry picked from commit 6579dfda17)
6 years ago
Tobias Rüetschi a79c57b1e1 Backport/2.7/55083 (#55141)
* The Univention modules have a issue with an unassigned variable.

The variable diff is only assigned if state is 'present', else the
variable is unused. But the module will return the diff variable as a
return value. If the state isn't 'present' the module will fail with an
python UnboundLocalError exception.

(cherry picked from commit 26fa97922a)

* Add a changelog fragment for PR 55083.

(cherry picked from commit b4ae654890)
6 years ago
Paul Puschmann 4b28413446 Backport/2.7/50183 (#55035)
* gcp: documentation update (#50183)

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>

(cherry picked from commit ae404d1476)

* Add changelog-document for gcp_inventory improvement
6 years ago
Robert Osowiecki 910d21e15c Allow all of yum version compare operators (#54603)
* Allow all of yum version compare operators

* * yum: name="foo >= VERSION" integration test
* changelog fragment

(cherry picked from commit 1532e31ec0)
6 years ago
Adam Miller d262f35789 fix dnf module removal in dnf upstream 4.2.2+ (#54923)
* fix dnf module removal in dnf upstream 4.2.2+

Signed-off-by: Adam Miller <admiller@redhat.com>

* Remove extra blank line in changelog fragment.
6 years ago
Felix Fontein 712e79eb5e ufw: fix default, direction is not necessary for it (#54799)
* Correct behavior so that direction isn't required for default.
* Add more tests.
* 'disabled' values cannot be changed.
* Include 'not specified' in messages.

(cherry picked from commit 7d27348356)
6 years ago
Kevin Breit 737cd948d6 Meraki performance fixes for net and org lookups (#51395)
* Performance fixes for net and org lookups
- Both methods had duplicate lookups
- This should significantly improve performance
- Currently untested

* Add ChangeLog file

* Change from bugfix to bugfixes and change indent

(cherry picked from commit c254b93796)
6 years ago
Felix Fontein eeb6ec1097 acme_certficate: allow to write files to CWD (#54754)
* Allow to write files to CWD.

* Add changelog.

(cherry picked from commit e422f18898)
6 years ago
Martin Krizek a8a318e588 Fix copy module to reset filesystem acls (#51868)
The controller's fixup_perms2 uses filesystem acls to make the temporary
file for copy readable by an unprivileged become user. On Python3, the
acls are then copied to the destination filename so we have to remove
them from there.

We can't remove them prior to the copy because we may not have
permission to read the file if the acls are not present. We can't
remove them in atomic_move() because the move function shouldn't know
anything about controller features. We may want to generalize this into
a helper function, though.

Fixes #44412

Co-authored-by: Toshio Kuratomi <a.badger@gmail.com>
(cherry picked from commit d15812fabf)
6 years ago
Trishna Guha b79d1002f8 changelog
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
6 years ago
Ganesh B Nalawade b6f52a4b81 Fix netconf plugin dispatch response
Fixes #53236

*  If dispatch() rpc response has data element
   return the xml string from `<data>` element
   else return the complete xml string from
   `<rpc-reply>`.

(cherry picked from commit aac5ef5e13)
6 years ago
Scott Luther 78ebe74b61 fix remove_orphans using APIs exposed via AnsibleDockerClient (#54316)
Co-Authored-By: sluther <neenach2002@gmail.com>

(cherry picked from commit 5517b0384f)
6 years ago
Toshio Kuratomi e75f58f305 New release v2.7.10 6 years ago
Łukasz Szczęsny 110b60fdb8 Backport/2.7/54105 pamd: fix idempotence issue when removing rules (#54105) 6 years ago
Evan Kaufman 384781d0ea [stable-2.7] replace - fixed combined before and after usage (#31452)
When using before and after in combination, the opposite behavior was induced. This PR makes the the replacement happen between the specified patterns as intended.

* Added integration tests
* Add changelog, porting guide entry, and minor doc fixes.
(cherry picked from commit cf69ec5db0)

Co-authored-by: Evan Kaufman <evan.kaufman@gmail.com>
6 years ago
Nathaniel Case fc2336aef2 Allow AnsibleVaultEncryptedUnicode to pass through exec_jsonrpc (#48306)
* Allow AnsibleVaultEncryptedUnicode to pass through exec_jsonrpc

* Add changelog

(cherry picked from commit f05979932b)

Conflicts:
	lib/ansible/module_utils/connection.py
6 years ago
Simon Westphahl 635ff3966f Catch all request timeouts for winrm connection (#54104)
* Catch all request timeouts for winrm connection

The current implementation only catches 'ConnectTimeout' exceptions.
Instead we should catch 'Timout' which also catches ReadTimeout
exceptions.

Improves on: #51744

Co-Authored-By: westphahl <westphahl@gmail.com>

* Changelog for winrm error handling improvement
6 years ago
Jordan Borean 71bec85253 win_user_right - fix non json output issue (#54495)
(cherry picked from commit e2d2874d81)
6 years ago
Anton Roman 68c5555cc5 [stable-2.7] fix issue in random_mac filter with short prefixes (#53928)
(cherry picked from commit 1e3428a766)

Co-authored-by: Anton Roman <antonroman@gmail.com>
6 years ago
Felix Fontein 13ab3a4f3d [2.7] openssl_certificate: fix state=absent (#54348)
* openssl_certificate: fix state=absent (#54298)

* Fix state=absent.

* Add changelog.

(cherry picked from commit 534c833bb3)

* openssl_certificate: update for #54298 (state=absent fix) (#54353)

* Update for #54298: Certificate is abstract, so instantiating doesn't work.

* Add test for removal.

(cherry picked from commit 5bb5c9d295)
6 years ago
Matt Williams 78844c800f Fix Foreman returning host parameters (#54101)
* Fix Foreman returning host parameters 

Foreman (1.20) returns the `all_parameters` key as a list of dicts, not a dict of key-value pairs.

* Fix for type error

The empty type here should be a dict, not a list as is has a `get` done
on it next.

(cherry picked from commit e94e80c79e)

* Return dict directly to avoid failing key lookup

(cherry picked from commit 545b98645d)

* Add changelog fragment for #54333
6 years ago
Yunge Zhu e31620e9db Backport/2.7/53496: fix azure_rm.py not showing nic info for vmss #53496 (#54379)
* fix azure_rm.py not showing nic info for vmss (#53496)

* fix vmss nic

* resolve comments

(cherry picked from commit 710b05fae7)

* add changelog
6 years ago
Yunge Zhu 1cc5196922 backport: add missing hostvars properties in azure_rm.py inventory (#53046) (#54318)
* add missing hostvars properties in azure_rm.py inventory (#53046)

* add missing hostvars properties

* fix lint

* fix lint

* add security group

* fix lint

(cherry picked from commit 71042e1a79)

* add changelog
6 years ago
Felix Fontein 59000d01b6 openssl_*: proper mode support (#54085)
* Add write helper.

* Adjust modules (except openssl_certificate).

* Adding tests for mode (with openssl_privatekey).

* Add openssl_certificate support.

* Never, ever remove the output file before actually trying to generate new content for it.

Removal is only allowed when state=absent, or when the object has been regenerated and the result needs to be written to that place.

* Add changelog.

* Extend test.

(cherry picked from commit d7a273273a)
6 years ago
Rémi REY e6bf08d9ec grafana_datasource: use the Ansible helpers to get basic auth header (#54183)
* grafana_datasource: use the Ansible helpers to get basic auth header

Module was not using the helpers, so an error occured in python3.

Fixes: #49147

* Update grafana_datasource_fix_basic_auth_python3_issue.yaml
6 years ago
Felix Fontein 3546594331 openssl_dhparam: fix state=absent (#54296)
* Fix remove.

* Add changelog.

(cherry picked from commit 121990d8c5)
6 years ago
René Moser ae5e6b5aef [2.7] include_tasks: fix traceback if no file specified (#54044) (#54164)
* include_tasks: fix traceback if no file specified (#54044)



(cherry picked from commit c5609c51bf)

* fix typo
6 years ago
Brian Coca 6e4c344a6b dict is dict (#54057)
(cherry picked from commit d1a688b1d7)
6 years ago
Alexander Bethke 9173941100 Handle empty output in remote_exists (backport of #52010 to 2.7) (#54103)
* flatpak_remote: Handle empty output in remote_exists (#52010)

`flatpak remote-list -d` can return an empty output on Fedora 29 (version 1.2.0).

(cherry picked from commit fcb6f136cd)

* Adds changelog fragment for 52010 backport
6 years ago
Felix Fontein 3d5bf87b9d openssl_publickey: fix handling of OpenSSH private keys with passphrase (#54192)
* Cleanup.
* Make sure that OpenSSH passphrases are handled correctly.
* Add changelog.

(cherry picked from commit 1a94cf140c)
6 years ago
Bill Dodd 1d55f4a4e5 Backport/2.7/51898 (#52100)
* remove non-standard GetManagerAttributes, SetManagerAttributes (#51898)

(cherry picked from commit 3b20b186d7)

* add changelog fragment

* fix merge error in default Manager command

* add back {Get/Set}ManagerAttributes commands and deprecate them
6 years ago
Lars Kellogg-Stedman e8dcf0f088 fix constructed functionality in openstack inventory plugin
This is a backport of #48833 for stable-2.7.

The compose, groups, and keyed_groups functionality of the openstack
inventory plugin was broken:

- the plugin was not passing the correct variables to the
  Constructable methods for compose and groups
- the plugin was simply never calling the appropriate method for
  implementing keyed_groups

This commit fixes both issues.

(cherry picked from commit 5a9c767662)
6 years ago
Pilou 7ef076db0e Backport/2.7/54028 tower_settings: "get" isn't implemented, "value" parameter is required (#54051)
* tower_settings: "get" isn't implemented, "value" parameter is required (#54028)

* tower_settings doc: 'get' isn't implemented

* tower_settings: fix typo in argument_spec

(cherry picked from commit ac7df0ef65)

* Add changelog fragment for tower_settings bugfix
6 years ago
Jordan Borean a11a56f27d win_psexec - support paths with a space (#54009)
(cherry picked from commit 7ab77f6c8a)
6 years ago
Jordan Borean c37646cf56 win_file - fix glob like paths (#54003)
(cherry picked from commit c053bc1fc7)
6 years ago
Jordan Borean 16be92f480 win_copy - fix glob like paths (#54006)
(cherry picked from commit 2f1bc34589)
6 years ago
Jordan Borean 0668265bdb win_certificate_store - fix glob like paths (#54007)
(cherry picked from commit eb18df1a0f)
6 years ago
Jordan Borean ee3a7033fd win_find - fix glob like paths (#54005)
(cherry picked from commit 8a4079ddbf)
6 years ago
Jordan Borean c8914a1678 windows - Fix module utils with glob paths (#53835)
* windows - Fix module utils with glob paths

* fix link util tests when using DOS 8.3 paths

(cherry picked from commit 980ca564ce)
6 years ago
Jordan Borean 19385f1ee1 win_slurp - fix glob like paths (#53831)
(cherry picked from commit d00418c924)
6 years ago
Jordan Borean edfc44ec51 win_owner - fix glob like paths (#53830)
* win_owner - fix glob like paths

* Fix issues on older PS versions

(cherry picked from commit d063cefb64)
6 years ago
Jordan Borean f9e6a89993 win_acl_inheritance - fix glob like paths (#53829)
(cherry picked from commit 3cfa71bff0)
6 years ago
Jordan Borean 73bf34ed41 win_acl - fix glob file paths (#53828)
(cherry picked from commit aba6f5f50d)
6 years ago
Jordan Borean b0c6499b60 win_tempfile - return absolute path on created temp file (#53827)
* win_tempfile - return absolute path on created temp file

* Fix tests for CI

(cherry picked from commit 4f9de45785)

8
6 years ago
Sam Doran 833b29b39c [stable-2.7] Correctly count processors on ARM systems. (#52884) (#53798)
* [stable-2.7] Correctly count processors on ARM systems. (#52884)

- Add unit tests for Linux CPU info
- Add cpuinfo output from several systems for unit tests

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
(cherry picked from commit 55306906cf)

Co-authored-by: Sam Doran <sdoran@redhat.com>

* Add changelog
6 years ago
Jordan Borean 4840952f3d win_reboot - Fix rc validation when using psrp and add extra docs - 2.7 (#53718)
* win_reboot - Fix rc validation when using psrp and add extra docs (#53711)

* win_reboot - Fix rc validation when using psrp and add extra docs

* Revert boot time command and fix docs

(cherry picked from commit 3d23e47c53)

* win_reboot - fix broken tests after recent commit (#53722)


(cherry picked from commit d9795bad98)
6 years ago
Matt Martz 166ef9f668 [stable-2.7] Fix checksum file parsing in get_url (#53685) (#53694)
* [stable-2.7] Fix checksum file parsing in get_url (#53685)

* Fix checksum file parsing. Fixes #48790

* guard invalid int conversion

Co-Authored-By: sivel <matt@sivel.net>

* Remove extra newline.
(cherry picked from commit 77217fdd24)

Co-authored-by: Matt Martz <matt@sivel.net>

* Remove use of undefined variable
6 years ago
Martin Krizek 81d893d6ee 2.7: yum: fix disable_excludes in repoquery fallback (#53697)
* yum: fix disable_excludes in repoquery fallback (#53552)

Fixes #53134

(cherry picked from commit 42731ec73f)

* Add changelog for #53552 (#53695)


(cherry picked from commit e0a7f01f0b)
6 years ago
Matt Martz abf5f7583e [stable-2.7] Don't raise AnsibleConnectionFailure if the ssh process has already died. (#53534)
* Don't raise AnsibleConnectionFailure if the ssh_process has already died. Fixes #53487

* Better support for file not found messages

* Add changelog fragment
(cherry picked from commit e9f9bca)

Co-authored-by: Matt Martz <matt@sivel.net>
6 years ago
Jordan Borean 0a03d0ee0e win_chocolatey - Fix incompatibilities with latest Chocolatey release (#53841)
(cherry picked from commit cac3c6efcf)
6 years ago
Toshio Kuratomi b4cba61b67 New release v2.7.9 6 years ago
Matt Clay 15c5d85251 [stable-2.7] Keep existing to_yaml behavior with pyyaml >= 5.1. (#53772)
In pyyaml versions before 5.1 the default_flow_style for yaml.dump
was None. Starting with 5.1 it is now False. This change explicitly
sets the value to None to maintain the original to_yaml behavior.

The change to pyyaml was made in the following commit:

507a464ce6
(cherry picked from commit 7f0e09aa31)

Co-authored-by: Matt Clay <matt@mystile.com>
6 years ago
Ryan Conway bd15658f2c Backport/2.7/51953 (#53657)
* Backporting the logical changes from #51953 to restore functionality on the newer 1Password CLIs v0.5.5+.

* Adding changelog fragment for this backport PR.
6 years ago
Felix Fontein ca63a2a968 docker_container: show warnings, fix/improve tests (#53440)
* Output warnings from docker daemon on container create and update.

* Accept warning for blkio_weight instead of idempotency.

* Value quoting.

* Avoid loop variable conflict.

* Add changelog.

* Make one test case faster.

* Add 'Docker warning: ' prefix.

* Add a generalized warning reporting function.

(cherry picked from commit 3117900b1e)
6 years ago
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
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 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 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 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
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
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
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
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 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 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
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