1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
Commit graph

278 commits

Author SHA1 Message Date
patchback[bot]
e3cea35f2c
Temporarily disable passwordstore lookup tests on macOS and OSX. (#2979) (#2982)
(cherry picked from commit 4ae392e5de)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-07-10 13:49:12 +02:00
patchback[bot]
6ca3e78d11
archive - adding dest_state return value and enhancing integration tests. (#2913) (#2973)
* Initial commit

* Adding changelog fragment

* fixing changelog fragment

* Updating documentation

* Applying review suggestions

(cherry picked from commit 288fe1cfc6)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
2021-07-10 13:19:53 +02:00
patchback[bot]
82e7e931a8
snap - fixed param order (#2918) (#2932)
* fixed param order

* added changelog fragment

* rebased and uncommented tests per PR

* added /snap link in RH

* typo in tests

* Update tests/integration/targets/snap/tasks/default.yml

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 9b02230477)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-07-03 17:04:42 +02:00
patchback[bot]
58d8469759
archive - fix removal failures for nested files with tar archives (#2923) (#2927)
* Initial commit

* Adding changelog fragment

(cherry picked from commit ffe505a798)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
2021-07-02 21:55:15 +02:00
patchback[bot]
6d5dbfd455
Add integration test for classic snap (#2920) (#2921)
* Add integration test for classic snap

* Add comments and check remove without classic

* Comment new tests for now

(cherry picked from commit 00aa1250ee)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-07-02 13:31:29 +00:00
patchback[bot]
9a9b0b04a5
Fix snap module, and module helper behavior on rc != 0 in output (#2912) (#2915)
* Try some snap fixes.

* Fix logic.

* Try to run tests privileged.

* Prevent failure on rc != 0.

* Fix formatting.

* Revert "Try to run tests privileged."

This reverts commit 77ca91f502.

* Try to run tests on RHEL instead.

* Make sure that snapd is running.

* Add changelog fragment.

* str -> to_native.

* Make sure that installed binary is actually found.

* Add check mode tests.

* Mention #2835 in changelog fragment.

(cherry picked from commit c63dc624b7)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-07-01 19:33:47 +02:00
patchback[bot]
7ef25be10c
Add integration tests for snap (#2907) (#2909)
* Add integration tests for snap

* Also test on fedora and remove snapd if it was not installed

* disable test for now

(cherry picked from commit a97d82be88)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-06-30 15:22:18 +02:00
patchback[bot]
1e848c56f2
yum_versionlock: fix idempotency when using wildcard (asterisk) (#2787) (#2896)
* Check idempotency on yum_versionlock

* Lock packages wildcard

* fix formatting

Co-authored-by: Felix Fontein <felix@fontein.de>

* Fix formatting in asserts

* little closer but not still there

* Import fnmatch

* Change check_mode logic

* Add check_mode for add

* Add changelog

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 0a9cf38118)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-06-27 17:00:05 +02:00
patchback[bot]
138b57230a
java_keystore: fix keystore type (#2516) (#2893)
* fix keystore type; update unit tests

* add changelog fragment

* document new param 'keystore_type'

* add keystore_type support (backward compatible)

* check JKS format with magic bytes
* update integration tests
* revert first changes in unit tests
* update changelog fragment

* fix magic bytes for python2/python3

* fix integration tests (irrelevant check_mode)

* fix unit test (keystore removed before failure => changed=true)

* fix typo

* fix spelling

* shorten a branch

* mock is_jks_or_pkcs12

* fix function path in unit tests

* Apply suggestions from code review (spelling)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>

* rename a method (module + unit tests)

* move ArgumentSpec class content to main()

* refactor create() to not loose existing keystore in case of error

* update unit tests

* add integration test (error handling)

* fix keystore backup cleanup

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
(cherry picked from commit 199ead85d0)

Co-authored-by: quidame <quidame@poivron.org>
2021-06-27 15:44:31 +02:00
patchback[bot]
28007079a4
ini_file: fix regression reported in #2578 (#2875) (#2887)
* Add regression test.

* Add more Unicode tests.

* Add fix.

* Add changelog.

* Work completely with Unicode.

* Update plugins/modules/files/ini_file.py

Co-authored-by: quidame <quidame@poivron.org>

Co-authored-by: quidame <quidame@poivron.org>
(cherry picked from commit 147425ef93)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-06-27 10:26:27 +02:00
patchback[bot]
769233808d
Redis: slave -> replica (#2867) (#2868)
* Redis: slave -> replica

* Fallback for old Redis versions in CI.

(cherry picked from commit 2d1f5408d3)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-06-24 22:50:16 +02:00
patchback[bot]
7361ca5430
archive - refactor and bugfix (#2816) (#2863)
* Initial Commit

* Further refinement

* Fixing archive name distortion for single file zips

* Applying initial review suggestions

* Updating path value for single target

* Adding test case for single target zip archiving

* Fixing integration for RHEL/FreeBSD on ansible 2.x

* Fixing integration second attempt

* Adding changelog fragment

* Updating changelog fragment

(cherry picked from commit 24dabda95b)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
2021-06-24 19:15:03 +02:00
patchback[bot]
20bda07aaf
gem_module: Add bindir option (#2837) (#2851)
* gem_module: Add bindir option

This option allows to specify directory to install executables, e.g.
`/home/user/bin` or `/home/user/.local/bin`. This comes especially handy
when used with user_install option as the default path of executables is
not in PATH.

* Update changelogs/fragments/gem_module_add_bindir_option.yml

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>

* gem_module: Integration tests for bindir option

* gem_module: Update Integration tests for bindir option

* gem_module: Update Integration tests for bindir option

Make sure gist is not installed system-wide prior the tests

* Revert "gem_module: Update Integration tests for bindir option"

This reverts commit 04eec6db27.

* Do not check "install_gem_result is changed" for ansible develop on openSUSE

* Revert "Do not check "install_gem_result is changed" for ansible develop on openSUSE"

This reverts commit 48ecb27889.

* gem_module: Use --norc to avoid surprises

Run install and uninstall actions with `--norc`. This way ansible has
more control over the way gems are installed.

* Revert "gem_module: Use --norc to avoid surprises"

This reverts commit 66f40bcfe6.

* gem_module: bindir - Ignore openSUSE Leap

* Update plugins/modules/packaging/language/gem.py

Co-authored-by: Felix Fontein <felix@fontein.de>

* gem_module: Use --norc to avoid surprises

Run install and uninstall actions with `--norc` when supported (rubygems >= 2.5.2).
This way ansible has more control over the way gems are installed.

* Try distutils.version instead of packaging

* ver is an list, not string

* ver is not list either but tuple

* Update changelogs/fragments/gem_module_add_bindir_option.yml

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>

* ver can be None (when can this happen?)

* gem: Add norc option

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Update plugins/modules/packaging/language/gem.py

Co-authored-by: Felix Fontein <felix@fontein.de>

* Use tuples to compare versions

* Apply suggestions from code review

Co-authored-by: Amin Vakil <info@aminvakil.com>

* Update plugins/modules/packaging/language/gem.py

Co-authored-by: Amin Vakil <info@aminvakil.com>

* lost norc option check is back

* Move handling norc option to separate function

* cosmetic

* fix for the previos commit

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Cache result of get_rubygems_version

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
Co-authored-by: Amin Vakil <info@aminvakil.com>
(cherry picked from commit ce35d88094)

Co-authored-by: Stanislav German-Evtushenko <ginermail@gmail.com>
2021-06-21 12:41:40 +02:00
patchback[bot]
a6bffa274c
flatpak - allow to add/remove multiple flatpaks at once (#2521) (#2822)
* reviving flatpack PR

* added changelog fragment

* adjusted integration tests per PR

* adjusted examples to use the full name of the module

* Use new local artifacts.

* Re-add StrictVersion import.

* Try to clean up PR.

* ...

* Use original name in installed/not installed list.

* More fixes.

* Work around flatpak bug.

* Fix bug I introduced.

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 3997d5fcc8)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-06-17 19:05:05 +02:00
patchback[bot]
9565be5e50
yum_versionlock: enable fedora34 integration test (#2543) (#2784)
* Re-enable Fedora 34

* Update procps-ng before anything in yum_versionlock integration test

* Move procps-ng installation to block

* Revert "Move procps-ng installation to block"

This reverts commit 3aa873a110.

* Update procps-ng only on Fedora 34

(cherry picked from commit 19549058ce)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-06-11 19:28:48 +02:00
patchback[bot]
ac543f5ef0
flatpak: add tests in CI, add no_dependencies parameter (#2751) (#2754)
* Similar version restrictions than flatpak_remote tests.

* ...

* Try to work around missing dependencies.

* Revert "Try to work around missing dependencies."

This reverts commit 66a4e38566.

* Add changelog.

* App8 -> App2; make sure that there are two apps App1 and App2.

* Fix forgotten variabe.

* Remove test notices.

* Seems like flatpak no longer supports file:// URLs.

The tests would need to be rewritten to offer the URL via http:// instead.

* Try local HTTP server for URL tests.

* ...

* Lint, add status check.

* Add boilerplate.

* Add 'ps aux'.

* Surrender to -f.

* Work around apparent flatpak bug.

* Fix YAML.

* Improve condition.

* Make sure test reruns behave better.

(cherry picked from commit bb37b67166)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-06-08 09:14:10 +02:00
patchback[bot]
dbc0fe8859
zypper_repository: fix idempotency on adding repo with releasever and basearch variables (#2722) (#2753)
* zypper_repository: Check idempotency on adding repo with releasever

* Name required when adding non-repo files.

* Initial try to fix releasever

* Replace re.sub with .replace

* name releaseverrepo releaseverrepo

* Change  to ansible_distribution_version for removing repo

* improve asserts format

* add changelog

* Fix changelog formatting

Co-authored-by: Felix Fontein <felix@fontein.de>

* improve command used for retrieving releasever variable

Co-authored-by: Felix Fontein <felix@fontein.de>

* add basearch replace

* Add basearch to changelog fragment

* Check for releasever and basearch only when they are there

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 94a53adff1)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-06-08 08:47:15 +02:00
patchback[bot]
42a1318fe3
Re-enable flatpak_remote tests (#2747) (#2749)
* Automate test repo creation, re-enable flatpak_remote tests.

* Linting.

* Another try.

(cherry picked from commit 4c50f1add7)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-06-07 21:39:17 +02:00
patchback[bot]
321fb6c974
Reduce stormssh searches based on host (#2568) (#2724)
* Reduce stormssh searches based on host

Due to the stormssh searches in the whole config values, we need to reduce the search results based on the full matching of the hosts

* Removed whitespaces in the blank line

* Added changelog fragment and tests for the fix.

* Added newline at the end of the changelog fragment

* Added newline at the end of the tests

* Fixed bug with name in tests

* Changed assertion for the existing host

* Update changelogs/fragments/2568-ssh_config-reduce-stormssh-searches-based-on-host.yml

Co-authored-by: Felix Fontein <felix@fontein.de>

* Adjusted tests

* New line at the end of the tests

Co-authored-by: Anton Nikolaev <anikolaev@apple.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 1a4af9bfc3)

Co-authored-by: Anton Nikolaev <drenout@gmail.com>
2021-06-05 18:03:14 +02:00
patchback[bot]
635d4f2138
Fix spurious test errors. (#2709) (#2710)
(cherry picked from commit 2e8746a8aa)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-06-04 10:24:55 +02:00
patchback[bot]
e74ea7c8b8
archive - Adding exclusion_patterns option (#2616) (#2686)
* Adding exclusion_patterns option

* Adding changelog fragment and Python 2.6 compatability

* Minor refactoring for readability

* Removing unneccessary conditional

* Applying initial review suggestions

* Adding missed review suggestion

(cherry picked from commit b6c0cc0b61)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
2021-05-31 08:16:40 +02:00
patchback[bot]
7483f71d31
iptables_state: fix broken query of async_status result (#2671) (#2676)
* use get() rather than querying the key directly

* add a changelog fragment

* re-enable CI tests

* Update changelog fragment

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit f09c39b71e)

Co-authored-by: quidame <quidame@poivron.org>
2021-05-29 13:58:03 +02:00
patchback[bot]
f7403a0b34
random_string: a new lookup plugin (#2572) (#2659)
New lookup plugin to generate random string based upon
constraints.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
(cherry picked from commit 43c12b82fa)

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
2021-05-27 20:16:50 +02:00
patchback[bot]
c242993291
Temporarily disable iptables_state tests. (#2641) (#2643)
(cherry picked from commit b45298bc43)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-05-27 08:28:45 +02:00
patchback[bot]
c12be67a69
ini_file - opening file as utf-8-sig (#2578) (#2591)
* opening file as utf-8-sig

* added changelog fragment

* using io.open()

* Update tests/integration/targets/ini_file/tasks/main.yml

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit cc293f90a2)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-05-22 22:42:02 +02:00
patchback[bot]
3a076fd585
Massive adjustment in integration tests for changed and failed (#2577) (#2584)
* Replaced ".changed ==" with "is [not] changed". Same for failed

* Mr Quote refused to go

(cherry picked from commit d7e55db99b)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-05-22 14:53:16 +02:00
patchback[bot]
936dd28395
java_cert - fix incorrect certificate alias on pkcs12 import (#2560) (#2581)
* fix wrong certificate alias used when importing pkcs12, modify error output, stdout is more relevant than stderr

* add changelog fragment

* fix changelog fragment

(cherry picked from commit 8f083d5d85)

Co-authored-by: absynth76 <58172580+absynth76@users.noreply.github.com>
2021-05-22 13:46:32 +02:00
patchback[bot]
43e766dd44
removed supporting code for testing module "nuage" - no longer exists here (#2559) (#2563)
(cherry picked from commit 452a185a23)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-05-19 22:23:36 +02:00
patchback[bot]
d43764da79
filesystem: revamp module (#2472) (#2550)
* revamp filesystem module to prepare next steps

* pass all commands to module.run_command() as lists
* refactor grow() and grow_cmd() to not need to override them so much
* refactor all existing get_fs_size() overrides to raise a ValueError if
  not able to parse command output and return an integer.
* override MKFS_FORCE_FLAGS the same way for all fstypes that require it
* improve documentation of limitations of the module regarding FreeBSD
* fix indentation in DOCUMENTATION
* add/update function/method docstrings
* fix pylint hints

filesystem: refactor integration tests

* Include *reiserfs* and *swap* in tests.
* Fix reiserfs related code and tests accordingly.
* Replace "other fs" (unhandled by this module), from *swap* to *minix*
  (both mkswap and mkfs.minix being provided by util-linux).
* Replace *dd* commands by *filesize* dedicated module.
* Use FQCNs and name the tasks.
* Update main tests conditionals.

* add a changelog fragment

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* declare variables as lists when lists are needed

* fix construction without useless conversion

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit f6db0745fc)

Co-authored-by: quidame <quidame@poivron.org>
2021-05-18 10:49:12 +02:00
patchback[bot]
38aa0ec8ad
Add option missing to passwordstore lookup (#2500) (#2541)
Add ability to ignore error on missing pass file to allow processing the
output further via another filters (mainly the default filter) without
updating the pass file itself.

It also contains the option to create the pass file, like the option
create=true does.

Finally, it also allows to issue a warning only, if the pass file is not
found.

(cherry picked from commit 350380ba8c)

Co-authored-by: Jan Baier <7996094+baierjan@users.noreply.github.com>
2021-05-17 14:14:44 +02:00
patchback[bot]
42f28048a8
yum_versionlock: disable fedora34 integration test (#2536) (#2538)
* Disable yum_versionlock integration test on Fedora 34

* Remove --assumeyes and add a comment regarding this

* Update update task name

(cherry picked from commit da7e4e1dc2)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-05-17 10:36:36 +02:00
patchback[bot]
b699aaff7b
Use --assumeyes with explicit yum call. (#2533) (#2535)
(cherry picked from commit 2cc848fe1a)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-05-17 08:27:25 +02:00
patchback[bot]
048f15fe68
java_keystore: New ssl_backend option for cryptography (#2485) (#2513)
* Adding cryptography as a backend for OpenSSL operations

* Updating unit tests and adding changelog fragment

* Allowing private key password option when using unprotected key

* Incorporating suggestions from initial review

* Centralizing module exit path

(cherry picked from commit a385cbb11d)

Co-authored-by: Ajpantuso <ajpantuso@gmail.com>
2021-05-14 22:47:26 +02:00
patchback[bot]
aa1aa1d540
random_pet: Random pet name generator (#2479) (#2509)
A lookup plugin to generate random pet names based
upon criteria.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
(cherry picked from commit 5d0a7f40f2)

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
2021-05-14 16:25:40 +02:00
patchback[bot]
bf185573a6
gitlab_user: add expires_at option (#2450) (#2506)
* gitlab_user: add expires_at option

* Add changelog

* Add integration test

* Add expires_at to addSshKeyToUser function

* password is required if state is set to present

* Check expires_at will not be added to a present ssh key

* add documentation about present ssh key

* add expires_at to unit tests

* Improve documentation

Co-authored-by: Felix Fontein <felix@fontein.de>

* Only pass expires_at to api when it is not None

* Emphasize on SSH public key

* Apply felixfontein suggestion

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 054eb90ae5)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-05-14 10:34:47 +02:00
patchback[bot]
6013c77c2b
Add groupby_as_dict filter (#2323) (#2503)
* Add groupby_as_dict filter.

* Test all error cases.

(cherry picked from commit 384655e15c)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-05-14 09:47:53 +02:00
patchback[bot]
ad5482f63d
Add proxmox_nic module (#2449) (#2502)
* Add proxmox_nic module

Add proxmox_nic module to manage NIC's on Qemu(KVM) VM's in a Proxmox VE
cluster.
Update proxmox integration tests and add tests for proxmox_nic module.

This partially solves https://github.com/ansible-collections/community.general/issues/1964#issuecomment-790499397
and allows for adding/updating/deleting network interface cards after
creating/cloning a VM.

The proxmox_nic module will keep MAC-addresses the same when updating a
NIC. It only changes when explicitly setting a MAC-address.

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Add check_mode and implement review comments

- check_mode added
- some documentation updates
- when MTU is set, check if the model is virtio, else fail
- trunks can now be provided as list of ints instead of vlanid[;vlanid...]

* Make returns on update_nic and delete_nic more readable

Co-authored-by: Felix Fontein <felix@fontein.de>

* Increase readability on update_nic and delete_nic

* Implement check in get_vmid

- get_vmid will now fail when multiple vmid's are returned as proxmox
  doesn't guarantee uniqueness
- remove an unused import
- fix a typo in an error message

* Add some error checking to get_vmid

- get_vmid will now return the error message when proxmoxer fails
- get_vmid will return the vmid directly instead of a list of one
- Some minor documentation updates

* Warn instead of fail when setting mtu on unsupported nic

- When setting the MTU on an unsupported NIC model (virtio is the only
  supported model) this module will now print a warning instead of
  failing.
- Some minor documentation updates.

* Take advantage of proxmox_auth_argument_spec

Make use of proxmox_auth_argument_spec from plugins/module_utils/proxmox.py
This provides some extra environment fallbacks.

* Add blank line to conform with pep8

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 23dda56913)

Co-authored-by: Kogelvis <github@ar-ix.net>
2021-05-14 09:47:39 +02:00
patchback[bot]
23da67cc72
Add dependent lookup plugin (#2164) (#2490)
* Add dependent lookup plugin.

* Use correct YAML booleans.

* Began complete rewrite.

* Only match start of error msg.

* Improve tests.

* Work around old Jinja2 versions.

* Fix metadata.

* Fix filter name.

(cherry picked from commit eea4f45965)

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-05-11 20:14:30 +02:00
patchback[bot]
797ea23e50
Clean up test entries from sysrc tests (#2330) (#2438)
* Clean up test entries from sysrc tests

* sysrc: enable tests

* sysrc: cache the files to be changed and restore them

* Update the ezjail archive host and remove obsolete file

* sysrc: set ezjail to use archives for 12.0 or less

* sysrc: Detect the version to use ftp vs ftp-archive using http

* sysrc: Skip ezjail test on FreeBSD 12.0

(cherry picked from commit 7007c68ab7)

Co-authored-by: David Lundgren <dlundgren@syberisle.net>
2021-05-03 21:34:19 +02:00
patchback[bot]
b920e8abf2
Add Fedora 34 to CI (#2384) (#2391)
* Add fedora 34 and fix typo

* Remove Fedora 32 from devel testing

* Use one newer version of Fedora for fixed ansible versions

* Revert "Use one newer version of Fedora for fixed ansible versions"

This reverts commit cbd006bd38.

* Try to skip task.

* Revert "Try to skip task."

This reverts commit ff0c899a86.

* Temporary disable Fedora 34 on setup_postgresql_db

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit ae21af8820)

Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-05-01 14:10:07 +02:00
Alexei Znamensky
99c564398a
jira - module revamp -> moved code to class (#2208)
* rebased after jira bugfix

* Update plugins/modules/web_infrastructure/jira.py

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-04-26 13:09:19 +02:00
Felix Fontein
e1d28cf052
Temporarily disable sysrc tests since they fail often. (#2318) 2021-04-21 13:37:10 +02:00
Ajpantuso
68243063d1
pids module: Adding pattern and ignore_case options (#2280)
* Adding pattern and ignore_case options

* Adding changelog fragment

* Fixing changelog fragment

* Addressing FreeBSD 11.4/python 3 errors with explicit conversion

* Correcting descriptions

* Reverting back to regex input

* Fixing test syntax errors
2021-04-21 12:45:09 +02:00
quidame
f87a39b21d
new module: filesize - create or resize a file, given its size (#2232)
* new module: filesize

* description: create or resize a file, given its size
* with integration tests

* Update plugins/modules/files/filesize.py (version_added)

Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>

* Update filesize.py (extends_documentation_fragment: use fqcn)

Co-authored-by: Amin Vakil <info@aminvakil.com>

* doc: use strict lowercase booleans (true/false) rather than other variants

* use *raw* type to manage size values

* drop 'miB' unit family

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* add more details

Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
Co-authored-by: Amin Vakil <info@aminvakil.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
2021-04-19 07:04:29 +02:00
Felix Fontein
91a0264f38
java_keystore: overwrite instead of fail when password or alias does not match (#2262)
* Overwrite instead of fail when password does not match.

* Update documentation.

* Fix tests.

* Update plugins/modules/system/java_keystore.py

Co-authored-by: Amin Vakil <info@aminvakil.com>

* Fix documentation.

* Apply suggestions from code review

Co-authored-by: quidame <quidame@poivron.org>

* Update tests/unit/plugins/modules/system/test_java_keystore.py

* One more.

Co-authored-by: Amin Vakil <info@aminvakil.com>
Co-authored-by: quidame <quidame@poivron.org>
2021-04-19 06:59:52 +02:00
Alexei Znamensky
ec9c23437c
cpanm - revamp module (#2218)
* copying from the previous branch

* passing sanity - docs incomplete

* adjusted parameter name

* adjusted unit tests for mode=new

* adjusted integration tests for mode=new

* added 'russoz' to list of maintainers for cpanm

* Update tests/integration/targets/cpanm/tasks/main.yml

* Update tests/integration/targets/cpanm/tasks/main.yml

* ensuring backward compatibility + tests

* added changelog fragment

* version for new parameter and adjusted example

* typo and formatting

* Update plugins/modules/packaging/language/cpanm.py

Co-authored-by: Felix Fontein <felix@fontein.de>

* Update plugins/modules/packaging/language/cpanm.py

Co-authored-by: Felix Fontein <felix@fontein.de>

* Update plugins/modules/packaging/language/cpanm.py

Co-authored-by: Felix Fontein <felix@fontein.de>

* multiple changes

- some fixes from PR
- supporting tests
- integration is no longer unsupported => destructive, should run on
  apt- and rpm-based systems only

* only run integration tests in redhat-family > v7 or debian-family

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-04-18 10:55:47 +02:00
Ajpantuso
118d903e7d
New filter plugins: hashids_encode and hashids_decode (#2244)
* New filters hashids_encode and hashids_decode

* Adding changelog

* Correcting whitespace issue in vars file

* Attempt to fix integration test failures

* Correcting copyright

* Addressing initial review comments

* Updating decoded sequence return from tuple to list

* Correcting capitilization and spelling
2021-04-17 20:00:03 +02:00
quidame
3a8206fe62
java_keystore: add certificate_path and private_key_path options (#2230)
* java_keystore: add `certificate_path` and `private_key_path` options

* Update DOCUMENTATION and EXAMPLES accordingly.
* Refactor integration tests to play the same tasks twice.
* Add a changelog fragment (minor_changes).

refactor DOCUMENTATION

* Add useful info for better understanding of what options allow
  keystore regeneration on the fly, and what other options lead the
  module to fail, if their values change.
* Fix indentation and tenses.
* Add myself as author.

* readability-related stuff + changelog fragment
2021-04-17 18:17:53 +02:00
tgates81
1f001cafd9
spectrum_model_attrs: Initial commit (#1802)
* spectrum_model_attrs: Initial commit

* spectrum_model_attrs: sanity check fixes (1)

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Apply suggestions from code review:
 * Removed ANSIBLE_METADATA.
 * List all currently supported names in DOCUMENTATION block.
 * Don't escape declarations that are long enough to fit on one
 line.

* Apply suggestions from code review:
  * YAML bools in DOCUMENTATION block.
  * Various DOCUMENTATION block aesthetics.
  * RETURN block proper format.
  * 'yes' -> True declaration in argument spec.
  * import urlencode from python 2 and 3 changed to
    six.moves.urllib.quote.

* spectrum_model_attrs: integration test added.

* Update plugins/modules/monitoring/spectrum_model_attrs.py

Co-authored-by: Amin Vakil <info@aminvakil.com>

* Update plugins/modules/monitoring/spectrum_model_attrs.py

Co-authored-by: Amin Vakil <info@aminvakil.com>

* spectrum_model_attrs: lint error fixes.

Co-authored-by: Tyler Gates <tgates@citco.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Amin Vakil <info@aminvakil.com>
2021-04-12 22:26:43 +02:00
quidame
89b7e7191f
java_keystore: improve error handling and returned results (#2183)
* java_keystore - improve error handling and returned results

* set check_rc=False to return results as documented when module fails
* set LANG, LC_ALL and LC_MESSAGES to C to rely keytool output parsing
* fix pylint's `no-else-return` and `unused-variable` hints
* update related unit tests accordingly
* add a changelog fragment

update unit test (remove stdout_lines from returned dict)

fix unit test: failure is now expected when alias does not exist

* Update changelogs/fragments/2183-java_keystore_improve_error_handling.yml

Co-authored-by: Felix Fontein <felix@fontein.de>

* fix integration test: overwrite keystore at the same location

Co-authored-by: Felix Fontein <felix@fontein.de>
2021-04-12 21:23:43 +02:00