* initial commit, passing unit tests
* passing one very silly integration test
* multiple changes:
- updated copyright year
- cmd_runner
- added fmt_optval
- created specific exceptions
- fixed bug in context class where values from module params were not
being used for resolving cmd arguments
- changed order of class declaration for readability purpose
- tests
- minor improvements in integration test code
- removed some extraneous code in msimple.yml
- minor improvements in unit tests
- added few missing cases to unit test
* multiple changes
cmd_runner.py
- renamed InvalidParameterName to MissingArgumentFormat
- improved exception parameters
- added repr and str to all exceptions
- added unpacking decorator for fmt functions
- CmdRunner
- improved parameter validation
- _CmdRunnerContext
- Context runs must now pass named arguments
- Simplified passing of additional arguments to module.run_command()
- Provided multiple context variables with info about the run
Integration tests
- rename msimple.py to cmd_echo.py for clarity
- added more test cases
* cmd_runner: env update can be passed to runner
* adding runner context info to output
* added comment on OrderedDict
* wrong variable
* refactored all fmt functions into static methods of a class
Imports should be simpler now, only one object fmt, with attr access to all callables
* added unit tests for CmdRunner
* fixed sanity checks
* fixed mock imports
* added more unit tests for CmdRunner
* terminology consistency
* multiple adjustments:
- remove extraneous imports
- renamed some variables
- added wrapper around arg formatters to handle individual arg ignore_none behaviour
* removed old code commented out in test
* multiple changes:
- ensure fmt functions return list of strings
- renamed fmt parameter from `option` to `args`
- renamed fmt.mapped to fmt.as_map
- simplified fmt.as_map
- added tests for fmt.as_fixed
* more improvements in formats
* fixed sanity
* args_order can be a string (to be split())
and improved integration test
* simplified integration test
* removed overkill str() on values - run_command does that for us
* as_list makes more sense than as_str in that context
* added changelog fragment
* Update plugins/module_utils/cmd_runner.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* adjusted __repr__ output for the exceptions
* added superclass object to classes
* added additional comment on the testcase sample/example
* suggestion from PR
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit f5b1b3c6f0)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* Allow restoring of snapshots
* Fix formatting
* Add documentation for new feature
* Revert unrelated reformatting
* Add documentation for snapshot change
* Remove redundant multiple call to status API
* Remove unneccesary indent
* Add documentation for timeout fix
* Update changelog fragment to reflect real changes
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update changelog fragment to reflect real changes
Co-authored-by: Felix Fontein <felix@fontein.de>
* Add Tests for Snapshot rollback
* Update tests/unit/plugins/modules/cloud/misc/test_proxmox_snap.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update changelogs/fragments/4377-allow-proxmox-snapshot-restoring.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/modules/cloud/misc/proxmox_snap.py
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit dbad1e0f11)
Co-authored-by: Timon Michel <ich.bin@ein.dev>
* Proxmox inventory: implement api token auth
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
* fix linter errors
* add changelog fragment
* add examples
* fix a typo and break long lines
* Update changelogs/fragments/4540-proxmox-inventory-token-auth.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit c8c2636676)
Co-authored-by: Daniel <mail@h3po.de>
* Fix keycloack realm parameters types
* Add changelog fragment
* Update changelog fragment
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 0620cd2e74)
Co-authored-by: Alexandr <36310479+Vespand@users.noreply.github.com>
* nmcli: Deprecate default hairpin mode
Deprecate the default hairpin mode for a bridge.
Plain nmcli/bridge tools defaults to no, but for some reason ansible
defaults to yes.
We deprecate the default value so we can switch to default 'no' in
ansible 6.0.0
* Code review fixes
Co-authored-by: Felix Fontein <felix@fontein.de>
* Fix comments
* Update changelogs/fragments/4320-nmcli-hairpin.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update changelogs/fragments/4320-nmcli-hairpin.yml
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
(cherry picked from commit 53f6c68026)
Co-authored-by: dupondje <jean-louis@dupond.be>
* Implement contructable support for opennebula inventory plugin: keyed_groups, compose, groups
* Fixed templating mock issues in unit tests, corrected some linting errors
* trying to make the linter happy
* Now trying to make python2.7 happy
* Added changelog fragment
* changelog fragment needs pluralization
* Update changelogs/fragments/4524-update-opennebula-inventory-plugin-to-match-documentation.yaml
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 8e72e98adb)
Co-authored-by: Bill Sanders <billysanders@gmail.com>
* remove deprecated branch.protect method
* add changelog fragment
* Update changelogs/fragments/4496-remove-deprecated-method-in-gitlab-branch-module.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit a8abb1a5bf)
Co-authored-by: York Wong <eth2net@gmail.com>
* Remove FreeBSD 12.0 and 12.2 from CI.
* Revert "Temporarily disable the pkgng tests. (#4493)"
This reverts commit 5ecac692de.
(cherry picked from commit 26cebb9c30)
Co-authored-by: Felix Fontein <felix@fontein.de>
* Adds optional `-upgrade` flag to terraform init.
This allows Terraform to install provider dependencies into an existing project when the provider constraints change.
* fix transposed documentation keys
* Add integration tests for terraform init
* Revert to validate_certs: yes for general public testing
* skip integration tests on irrelevant platforms
* skip legacy Python versions from CI tests
* add changelog fragment
* Update plugins/modules/cloud/misc/terraform.py
Adds version_added metadata to the new module option.
Co-authored-by: Felix Fontein <felix@fontein.de>
* Change terraform_arch constant to Ansible fact mapping
* correct var typo, clarify task purpose
* Squashed some logic bugs, added override for local Terraform
If `existing_terraform_path` is provided, the playbook will not download Terraform or check its version.
I also tested this on a local system with Terraform installed, and squashed some bugs related to using of an
existing binary.
* revert to previous test behavior for TF install
* readability cleanup
* Update plugins/modules/cloud/misc/terraform.py
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit e4a25beedc)
Co-authored-by: Kamil Markowicz <geekifier@users.noreply.github.com>
* pacman: Fix removing locally installed packages
Without this, using `absent` state for a locally installed package (for example from AUR, or from a package that was dropped from repositories) would return that package is already removed, despite remaining installed
* Undo unwanted whitespace removal
* Add changelog fragment
* Update changelogs/fragments/4464-pacman-fix-local-remove.yaml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Add test.
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 3c515dd221)
Co-authored-by: Martin <spleefer90@gmail.com>
If `all=True` is not set then by default only 20 records will be
returned when calling `list()`. Use `all=True` so that all records
will be returned.
For the `list()` use where do not desire to retrieve all entries then
use`all=False` to show explicityly that we don't want to get all of
the entries.
Fixes: #3729Fixes: #4460
(cherry picked from commit fe4bbc5de3)
Co-authored-by: John Villalovos <john@sodarock.com>
* Only get monitor if it is not null api response
* Add changelog fragment
* Update changelogs/fragments/4459-only-get-monitor-if-it-is-not-null-api-response.yaml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/modules/net_tools/dnsmadeeasy.py
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: drevai <revai.dominik@gravityrd.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 06675034fe)
Co-authored-by: drevai753 <86595897+drevai753@users.noreply.github.com>
* Implement btrfs resize support
* Add changelog fragment for btrfs resize support
Co-authored-by: Fabian Klemp <fabian.klemp@frequentis.com>
(cherry picked from commit 8ccc4d1fbb)
Co-authored-by: elara-leitstellentechnik <elara-leitstellentechnik@users.noreply.github.com>
* add support for datadog monitors of type event-v2
See https://docs.datadoghq.com/events/guides/migrating_to_new_events_features/
* add changelog fragement for PR
* typos
* add link to PR
* minor_fetaure, not bugfix
* add to description when we added event-v2 type
* Update changelogs/fragments/4457-support-datadog-monitors-type event-v2.yaml
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 6edc176143)
Co-authored-by: ermeaney <ermeaney@gmail.com>
The previous error message was not giving the full or even correct
information to the user.
(cherry picked from commit d3adde4739)
Co-authored-by: Cameron Nemo <CameronNemo@users.noreply.github.com>
* Add error handling to check correct SDK version installed
* Fix CI errors
* Added changelog fragment
* Changed exeption type
* Update changelogs fragment
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit e7ffa76db6)
Co-authored-by: Ricky White <rickywhite@outlook.com>
* suggest new routes4 and routes6 format
* make new options instead of modifying exiting one
* fix docs and some small errors
* fixing docs
(cherry picked from commit feb0fffd58)
Co-authored-by: Alex Groshev <38885591+haddystuff@users.noreply.github.com>
* fixed issue with specified package versions
zypper.py was doing nothing on state=present, when ALL requestet/checked packages had a specific version stated. This was caused by get_installed_state() being called with an empty package list, which in this case returns information about all ALL installed packages. This lead to an exessive filter list prerun_state, essentially removing all packages that are installed in ANY version on the target system from the request list.
* Create 4421-zypper_package_version_handling_fix
added changelog fragment for https://github.com/ansible-collections/community.general/pull/4421
* Delete 4421-zypper_package_version_handling_fix
* Create 4421-zypper_package_version_handling_fix.yml
(cherry picked from commit bbe231e261)
Co-authored-by: tover99 <101673769+tover99@users.noreply.github.com>
* ensure creation of /etc/cron.d in test
* fixed typo
(cherry picked from commit 9e0ff8ba4b)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* [WIP] pids: re-enabled tests on Alpine Linux
* trying to compile a simple-faked sleep command
* make FreeBSD happy
* remove the block testing for Alpine Linux
* simpler version of sleeper.c
* simpler version of sleeper.c, part II
* Update tests/integration/targets/pids/tasks/main.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update tests/integration/targets/pids/tasks/main.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* added license to sleeper.c file
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 21ee4c84b7)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* added templating to the url, user, and password
* added changelog fragment
* typo in description for url, and password
* clarify in the changelog what can you change
* update documentation and added an example
* missing quote from examples
* Apply suggestions from code review
Changed to I for option names
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/inventory/proxmox.py
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 13d18c9aa8)
Co-authored-by: Ilija Matoski <ilijamt@gmail.com>