Compare commits

..

15 Commits

Author SHA1 Message Date
Felix Fontein
48c50fa335 Release 11.2.1. 2025-08-18 21:17:43 +02:00
patchback[bot]
a1e2ada993 [PR #10663/b9385d7f backport][stable-11] pacemaker_resource: Fix resource_type parameter (#10699)
pacemaker_resource: Fix resource_type parameter (#10663)

* Ensure resource standard, provider, and name are proper format

* Add changelog fragment

* Update changelogs/fragments/10663-pacemaker-resource-fix-resource-type.yml



---------


(cherry picked from commit b9385d7fe8)

Co-authored-by: Dexter <45038532+munchtoast@users.noreply.github.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-18 20:26:48 +02:00
patchback[bot]
d7eb5432f3 [PR #10695/6827680c backport][stable-11] build(deps): bump actions/checkout from 4 to 5 in the ci group (#10698)
build(deps): bump actions/checkout from 4 to 5 in the ci group (#10695)

Bumps the ci group with 1 update: [actions/checkout](https://github.com/actions/checkout).

Updates `actions/checkout` from 4 to 5
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: ci
...



(cherry picked from commit 6827680cda)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-18 18:34:01 +02:00
patchback[bot]
26f19db2f8 [PR #10687/47e8a3c1 backport][stable-11] ansible-core 2.20: avoid deprecated functionality (#10693)
ansible-core 2.20: avoid deprecated functionality (#10687)

Avoid deprecated functionality.

(cherry picked from commit 47e8a3c193)

Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-18 05:18:31 +00:00
patchback[bot]
8bc0c103ad [PR #10688/ceba0cbe backport][stable-11] pids: avoid type error if name is empty (#10692)
pids: avoid type error if name is empty (#10688)

Avoid type error if name is empty.

(cherry picked from commit ceba0cbedb)

Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-18 06:41:18 +02:00
Felix Fontein
0e495aae75 Add missing changelog fragment. 2025-08-17 22:35:33 +02:00
patchback[bot]
840b1b82ac [PR #10617/c84f16c5 backport][stable-11] scaleway_lb: fix RETURN docs (#10686)
scaleway_lb: fix RETURN docs (#10617)

* scaleway_lb: fix RETURN docs

* remove outer dict from sample content

(cherry picked from commit c84f16c5e9)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-08-17 17:28:39 +02:00
patchback[bot]
2b08a308bc [PR #10423/735a066d backport][stable-11] apache2_module: updated cgi action conditions (#10682)
apache2_module: updated cgi action conditions (#10423)

* apache2_module: updated cgi action conditions

Only the activation of the cgi module in threaded mode should be a
restriction due to apache2 limitations, not the deactivation.
Especially when the cgi module isn't enabled yet at all. Fixes #9140

* bug(fix): apache2_module fails to disable cgi module

* Update changelog fragment.

---------


(cherry picked from commit 735a066d92)

Co-authored-by: Daniel Hoffend <dh@dotlan.net>
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-17 13:12:55 +02:00
patchback[bot]
04305e8d9d [PR #10669/13bd4b5d backport][stable-11] composer: fix command args as list rather than string (#10680)
composer: fix command args as list rather than string (#10669)

(cherry picked from commit 13bd4b5d82)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-08-17 12:53:22 +02:00
Felix Fontein
15109a26fd Prepare 11.2.1. 2025-08-17 12:45:16 +02:00
patchback[bot]
d1730adce0 [PR #10674/dfc2a54d backport][stable-11] pacman: temporary disable yay test (#10678)
pacman: temporary disable yay test (#10674)

Temporary disable pacman yay test.

(cherry picked from commit dfc2a54d16)

Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-15 21:03:35 +02:00
patchback[bot]
69d7cce55c [PR #10668/d84d2397 backport][stable-11] ipa_*: adjust common connection notes to modules (#10671)
ipa_*: adjust common connection notes to modules (#10668)

(cherry picked from commit d84d2397b9)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-08-15 20:14:13 +02:00
patchback[bot]
d80aca951c [PR #10657/3c0d6074 backport][stable-11] jc filter: remove skips for FreeBSD (#10659)
jc filter: remove skips for FreeBSD (#10657)

(cherry picked from commit 3c0d60740c)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-08-12 09:58:11 +02:00
patchback[bot]
6f5462fb27 [PR #10653/eb5708a1 backport][stable-11] CI: Make sure to install Java in Debian Bullseye (#10656)
CI: Make sure to install Java in Debian Bullseye (#10653)

Make sure to install Java in Debian Bullseye.

(cherry picked from commit eb5708a125)

Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-12 01:21:35 +02:00
Felix Fontein
1c5c622ae8 There might be a 11.2.1 coming up next. 2025-08-11 22:34:04 +02:00
40 changed files with 202 additions and 92 deletions

View File

@@ -24,7 +24,7 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@v5
with:
persist-credentials: false

View File

@@ -21,7 +21,7 @@ jobs:
name: "Run extra sanity tests"
steps:
- name: Check out collection
uses: actions/checkout@v4
uses: actions/checkout@v5
with:
persist-credentials: false
- name: Run nox

View File

@@ -2,37 +2,40 @@
**Topics**
- <a href="#v11-2-0">v11\.2\.0</a>
- <a href="#v11-2-1">v11\.2\.1</a>
- <a href="#release-summary">Release Summary</a>
- <a href="#bugfixes">Bugfixes</a>
- <a href="#v11-2-0">v11\.2\.0</a>
- <a href="#release-summary-1">Release Summary</a>
- <a href="#minor-changes">Minor Changes</a>
- <a href="#deprecated-features">Deprecated Features</a>
- <a href="#bugfixes">Bugfixes</a>
- <a href="#bugfixes-1">Bugfixes</a>
- <a href="#new-plugins">New Plugins</a>
- <a href="#lookup">Lookup</a>
- <a href="#new-modules">New Modules</a>
- <a href="#v11-1-2">v11\.1\.2</a>
- <a href="#release-summary-1">Release Summary</a>
- <a href="#minor-changes-1">Minor Changes</a>
- <a href="#bugfixes-1">Bugfixes</a>
- <a href="#v11-1-1">v11\.1\.1</a>
- <a href="#release-summary-2">Release Summary</a>
- <a href="#minor-changes-2">Minor Changes</a>
- <a href="#minor-changes-1">Minor Changes</a>
- <a href="#bugfixes-2">Bugfixes</a>
- <a href="#v11-1-0">v11\.1\.0</a>
- <a href="#v11-1-1">v11\.1\.1</a>
- <a href="#release-summary-3">Release Summary</a>
- <a href="#minor-changes-2">Minor Changes</a>
- <a href="#bugfixes-3">Bugfixes</a>
- <a href="#v11-1-0">v11\.1\.0</a>
- <a href="#release-summary-4">Release Summary</a>
- <a href="#minor-changes-3">Minor Changes</a>
- <a href="#deprecated-features-1">Deprecated Features</a>
- <a href="#bugfixes-3">Bugfixes</a>
- <a href="#bugfixes-4">Bugfixes</a>
- <a href="#new-plugins-1">New Plugins</a>
- <a href="#callback">Callback</a>
- <a href="#new-modules-1">New Modules</a>
- <a href="#v11-0-0">v11\.0\.0</a>
- <a href="#release-summary-4">Release Summary</a>
- <a href="#release-summary-5">Release Summary</a>
- <a href="#minor-changes-4">Minor Changes</a>
- <a href="#deprecated-features-2">Deprecated Features</a>
- <a href="#removed-features-previously-deprecated">Removed Features \(previously deprecated\)</a>
- <a href="#security-fixes">Security Fixes</a>
- <a href="#bugfixes-4">Bugfixes</a>
- <a href="#bugfixes-5">Bugfixes</a>
- <a href="#known-issues">Known Issues</a>
- <a href="#new-plugins-2">New Plugins</a>
- <a href="#callback-1">Callback</a>
@@ -43,10 +46,27 @@
- <a href="#new-modules-2">New Modules</a>
This changelog describes changes after version 10\.0\.0\.
<a id="v11-2-1"></a>
## v11\.2\.1
<a id="release-summary"></a>
### Release Summary
Bugfix release\.
<a id="bugfixes"></a>
### Bugfixes
* Avoid deprecated functionality in ansible\-core 2\.20 \([https\://github\.com/ansible\-collections/community\.general/pull/10687](https\://github\.com/ansible\-collections/community\.general/pull/10687)\)\.
* apache2\_module \- check the <code>cgi</code> module restrictions only during activation \([https\://github\.com/ansible\-collections/community\.general/pull/10423](https\://github\.com/ansible\-collections/community\.general/pull/10423)\)\.
* composer \- fix broken command lines \([https\://github\.com/ansible\-collections/community\.general/issues/10662](https\://github\.com/ansible\-collections/community\.general/issues/10662)\, [https\://github\.com/ansible\-collections/community\.general/pull/10669](https\://github\.com/ansible\-collections/community\.general/pull/10669)\)\.
* pacemaker\_resource \- fix <code>resource\_type</code> parameter formatting \([https\://github\.com/ansible\-collections/community\.general/issues/10426](https\://github\.com/ansible\-collections/community\.general/issues/10426)\, [https\://github\.com/ansible\-collections/community\.general/pull/10663](https\://github\.com/ansible\-collections/community\.general/pull/10663)\)\.
* pids \- prevent error when an empty string is provided for <code>name</code> \([https\://github\.com/ansible\-collections/community\.general/issues/10672](https\://github\.com/ansible\-collections/community\.general/issues/10672)\, [https\://github\.com/ansible\-collections/community\.general/pull/10688](https\://github\.com/ansible\-collections/community\.general/pull/10688)\)\.
<a id="v11-2-0"></a>
## v11\.2\.0
<a id="release-summary"></a>
<a id="release-summary-1"></a>
### Release Summary
Regular bugfix and features release\.
@@ -89,7 +109,7 @@ Regular bugfix and features release\.
* github\_repo \- deprecate <code>force\_defaults\=true</code> \([https\://github\.com/ansible\-collections/community\.general/pull/10435](https\://github\.com/ansible\-collections/community\.general/pull/10435)\)\.
* rocketchat \- the default value for <code>is\_pre740</code>\, currently <code>true</code>\, is deprecated and will change to <code>false</code> in community\.general 13\.0\.0 \([https\://github\.com/ansible\-collections/community\.general/pull/10490](https\://github\.com/ansible\-collections/community\.general/pull/10490)\)\.
<a id="bugfixes"></a>
<a id="bugfixes-1"></a>
### Bugfixes
* jenkins\_plugin \- install latest compatible version instead of latest \([https\://github\.com/ansible\-collections/community\.general/issues/854](https\://github\.com/ansible\-collections/community\.general/issues/854)\, [https\://github\.com/ansible\-collections/community\.general/pull/10346](https\://github\.com/ansible\-collections/community\.general/pull/10346)\)\.
@@ -113,7 +133,7 @@ Regular bugfix and features release\.
<a id="v11-1-2"></a>
## v11\.1\.2
<a id="release-summary-1"></a>
<a id="release-summary-2"></a>
### Release Summary
Bugfix release\.
@@ -252,7 +272,7 @@ Bugfix release\.
* zypper \- remove redundant constructs from argument specs \([https\://github\.com/ansible\-collections/community\.general/pull/10513](https\://github\.com/ansible\-collections/community\.general/pull/10513)\)\.
* zypper\_repository \- remove redundant constructs from argument specs \([https\://github\.com/ansible\-collections/community\.general/pull/10513](https\://github\.com/ansible\-collections/community\.general/pull/10513)\)\.
<a id="bugfixes-1"></a>
<a id="bugfixes-2"></a>
### Bugfixes
* apk \- fix check for empty/whitespace\-only package names \([https\://github\.com/ansible\-collections/community\.general/pull/10532](https\://github\.com/ansible\-collections/community\.general/pull/10532)\)\.
@@ -266,7 +286,7 @@ Bugfix release\.
<a id="v11-1-1"></a>
## v11\.1\.1
<a id="release-summary-2"></a>
<a id="release-summary-3"></a>
### Release Summary
Bugfix release for the next Ansible 12 pre\-release\.
@@ -302,7 +322,7 @@ Bugfix release for the next Ansible 12 pre\-release\.
* filesystem \- remove redundant constructs from argument specs \([https\://github\.com/ansible\-collections/community\.general/pull/10494](https\://github\.com/ansible\-collections/community\.general/pull/10494)\)\.
* sysrc \- adjustments to the code \([https\://github\.com/ansible\-collections/community\.general/pull/10417](https\://github\.com/ansible\-collections/community\.general/pull/10417)\)\.
<a id="bugfixes-2"></a>
<a id="bugfixes-3"></a>
### Bugfixes
* apache2\_module \- avoid ansible\-core 2\.19 deprecation \([https\://github\.com/ansible\-collections/community\.general/pull/10459](https\://github\.com/ansible\-collections/community\.general/pull/10459)\)\.
@@ -320,7 +340,7 @@ Bugfix release for the next Ansible 12 pre\-release\.
<a id="v11-1-0"></a>
## v11\.1\.0
<a id="release-summary-3"></a>
<a id="release-summary-4"></a>
### Release Summary
Regular bugfix and feature release\.
@@ -380,7 +400,7 @@ Regular bugfix and feature release\.
* catapult \- module is deprecated and will be removed in community\.general 13\.0\.0 \([https\://github\.com/ansible\-collections/community\.general/issues/10318](https\://github\.com/ansible\-collections/community\.general/issues/10318)\, [https\://github\.com/ansible\-collections/community\.general/pull/10329](https\://github\.com/ansible\-collections/community\.general/pull/10329)\)\.
* pacemaker\_cluster \- the parameter <code>state</code> will become a required parameter in community\.general 12\.0\.0 \([https\://github\.com/ansible\-collections/community\.general/pull/10227](https\://github\.com/ansible\-collections/community\.general/pull/10227)\)\.
<a id="bugfixes-3"></a>
<a id="bugfixes-4"></a>
### Bugfixes
* dependent lookup plugin \- avoid deprecated ansible\-core 2\.19 functionality \([https\://github\.com/ansible\-collections/community\.general/pull/10359](https\://github\.com/ansible\-collections/community\.general/pull/10359)\)\.
@@ -406,7 +426,7 @@ Regular bugfix and feature release\.
<a id="v11-0-0"></a>
## v11\.0\.0
<a id="release-summary-4"></a>
<a id="release-summary-5"></a>
### Release Summary
This is release 11\.0\.0 of <code>community\.general</code>\, released on 2025\-06\-16\.
@@ -805,7 +825,7 @@ This is release 11\.0\.0 of <code>community\.general</code>\, released on 2025\-
* keycloak\_authentication \- API calls did not properly set the <code>priority</code> during update resulting in incorrectly sorted authentication flows\. This apparently only affects Keycloak 25 or newer \([https\://github\.com/ansible\-collections/community\.general/pull/9263](https\://github\.com/ansible\-collections/community\.general/pull/9263)\)\.
* keycloak\_client \- Sanitize <code>saml\.encryption\.private\.key</code> so it does not show in the logs \([https\://github\.com/ansible\-collections/community\.general/pull/9621](https\://github\.com/ansible\-collections/community\.general/pull/9621)\)\.
<a id="bugfixes-4"></a>
<a id="bugfixes-5"></a>
### Bugfixes
* apache2\_mod\_proxy \- make compatible with Python 3 \([https\://github\.com/ansible\-collections/community\.general/pull/9762](https\://github\.com/ansible\-collections/community\.general/pull/9762)\)\.

View File

@@ -6,6 +6,23 @@ Community General Release Notes
This changelog describes changes after version 10.0.0.
v11.2.1
=======
Release Summary
---------------
Bugfix release.
Bugfixes
--------
- Avoid deprecated functionality in ansible-core 2.20 (https://github.com/ansible-collections/community.general/pull/10687).
- apache2_module - check the ``cgi`` module restrictions only during activation (https://github.com/ansible-collections/community.general/pull/10423).
- composer - fix broken command lines (https://github.com/ansible-collections/community.general/issues/10662, https://github.com/ansible-collections/community.general/pull/10669).
- pacemaker_resource - fix ``resource_type`` parameter formatting (https://github.com/ansible-collections/community.general/issues/10426, https://github.com/ansible-collections/community.general/pull/10663).
- pids - prevent error when an empty string is provided for ``name`` (https://github.com/ansible-collections/community.general/issues/10672, https://github.com/ansible-collections/community.general/pull/10688).
v11.2.0
=======

View File

@@ -1577,3 +1577,24 @@ releases:
name: binary_file
namespace: null
release_date: '2025-08-11'
11.2.1:
changes:
bugfixes:
- Avoid deprecated functionality in ansible-core 2.20 (https://github.com/ansible-collections/community.general/pull/10687).
- apache2_module - check the ``cgi`` module restrictions only during activation
(https://github.com/ansible-collections/community.general/pull/10423).
- composer - fix broken command lines (https://github.com/ansible-collections/community.general/issues/10662,
https://github.com/ansible-collections/community.general/pull/10669).
- pacemaker_resource - fix ``resource_type`` parameter formatting (https://github.com/ansible-collections/community.general/issues/10426,
https://github.com/ansible-collections/community.general/pull/10663).
- pids - prevent error when an empty string is provided for ``name`` (https://github.com/ansible-collections/community.general/issues/10672,
https://github.com/ansible-collections/community.general/pull/10688).
release_summary: Bugfix release.
fragments:
- 10423-apache_module-condition.yml
- 10663-pacemaker-resource-fix-resource-type.yml
- 10680-composer.yml
- 10687-deprecations.yml
- 10688-pids.yml
- 11.2.1.yml
release_date: '2025-08-18'

View File

@@ -5,7 +5,7 @@
namespace: community
name: general
version: 11.2.0
version: 11.2.1
readme: README.md
authors:
- Ansible (https://github.com/ansible)

View File

@@ -94,7 +94,7 @@ EXAMPLES = r"""
from re import compile as re_compile
from ansible.plugins.become import BecomeBase
from ansible.module_utils._text import to_bytes
from ansible.module_utils.common.text.converters import to_bytes
ansi_color_codes = re_compile(to_bytes(r'\x1B\[[0-9;]+m'))

View File

@@ -80,7 +80,7 @@ EXAMPLES = r"""
from re import compile as re_compile
from ansible.plugins.become import BecomeBase
from ansible.module_utils._text import to_bytes
from ansible.module_utils.common.text.converters import to_bytes
ansi_color_codes = re_compile(to_bytes(r"\x1B\[[0-9;]+m"))

View File

@@ -54,7 +54,7 @@ from multiprocessing import Lock
from itertools import chain
from ansible.errors import AnsibleError
from ansible.module_utils.common._collections_compat import MutableSet
from collections.abc import MutableSet
from ansible.plugins.cache import BaseCacheModule
from ansible.utils.display import Display

View File

@@ -28,7 +28,7 @@ except ImportError:
pass
from ansible.module_utils.six import binary_type, text_type
from ansible.module_utils.common._collections_compat import MutableMapping, MutableSequence
from collections.abc import MutableMapping, MutableSequence
from ansible.plugins.callback.default import CallbackModule as CallbackModule_default
from ansible.utils.color import colorize, hostcolor
from ansible.utils.display import Display

View File

@@ -34,7 +34,7 @@ import json
from ansible.utils.path import makedirs_safe
from ansible.module_utils.common.text.converters import to_bytes
from ansible.module_utils.common._collections_compat import MutableMapping
from collections.abc import MutableMapping
from ansible.parsing.ajson import AnsibleJSONEncoder
from ansible.plugins.callback import CallbackBase

View File

@@ -80,7 +80,7 @@ from subprocess import call, Popen, PIPE
from ansible.errors import AnsibleError, AnsibleConnectionFailure, AnsibleFileNotFound
from ansible.module_utils.common.process import get_bin_path
from ansible.module_utils._text import to_bytes, to_text
from ansible.module_utils.common.text.converters import to_bytes, to_text
from ansible.plugins.connection import ConnectionBase

View File

@@ -80,5 +80,6 @@ options: {}
notes:
- This module uses JSON-RPC over HTTP(S) to communicate with the FreeIPA server.
If you need to enroll the managed node into FreeIPA realm, you might want to consider using the collection
L(freeipa.ansible_freeipa, https://galaxy.ansible.com/ui/repo/published/freeipa/ansible_freeipa/), but that will require shell access to the managed node.
L(freeipa.ansible_freeipa, https://galaxy.ansible.com/ui/repo/published/freeipa/ansible_freeipa/), but shell access to one
node from the realm is required to manage the deployment.
"""

View File

@@ -36,7 +36,7 @@ _value:
"""
from ansible.errors import AnsibleFilterError
from ansible.module_utils.common._collections_compat import Sequence
from collections.abc import Sequence
from collections import Counter

View File

@@ -54,7 +54,7 @@ _value:
"""
from ansible.errors import AnsibleFilterError
from ansible.module_utils.common._collections_compat import Mapping, Sequence
from collections.abc import Mapping, Sequence
def groupby_as_dict(sequence, attribute):

View File

@@ -197,7 +197,7 @@ _value:
from ansible.errors import AnsibleFilterError
from ansible.module_utils.six import string_types
from ansible.module_utils.common._collections_compat import Mapping, Sequence
from collections.abc import Mapping, Sequence
from ansible.utils.vars import merge_hash
from collections import defaultdict

View File

@@ -51,7 +51,7 @@ _value:
from ansible.errors import AnsibleFilterError
from ansible.module_utils.common._collections_compat import Mapping
from collections.abc import Mapping
from ansible.module_utils.six.moves import StringIO
from ansible.module_utils.six.moves.configparser import ConfigParser

View File

@@ -116,7 +116,7 @@ except ImportError:
HAS_PRETTYTABLE = False
from ansible.errors import AnsibleFilterError
from ansible.module_utils._text import to_text
from ansible.module_utils.common.text.converters import to_text
from ansible.module_utils.six import string_types

View File

@@ -78,7 +78,7 @@ from subprocess import Popen, PIPE
from ansible.errors import AnsibleParserError
from ansible.module_utils.common.text.converters import to_bytes, to_text
from ansible.module_utils.common._collections_compat import MutableMapping
from collections.abc import MutableMapping
from ansible.plugins.inventory import BaseInventoryPlugin, Constructable, Cacheable
from ansible.module_utils.common.process import get_bin_path

View File

@@ -121,7 +121,7 @@ _list:
"""
from ansible.errors import AnsibleLookupError
from ansible.module_utils.common._collections_compat import Mapping, Sequence
from collections.abc import Mapping, Sequence
from ansible.module_utils.six import string_types
from ansible.plugins.lookup import LookupBase
from ansible.template import Templar

View File

@@ -31,7 +31,7 @@ except ImportError:
from ansible.module_utils import six
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
from ansible.module_utils.common.text.converters import to_native
from ansible.module_utils.common._collections_compat import Mapping
from ansible.module_utils.six.moves.collections_abc import Mapping
def transform_list_to_dict(list_):

View File

@@ -24,7 +24,7 @@ _state_map = {
def fmt_resource_type(value):
return [value[k] for k in ['resource_standard', 'resource_provider', 'resource_name'] if value.get(k) is not None]
return [":".join(value[k] for k in ['resource_standard', 'resource_provider', 'resource_name'] if value.get(k) is not None)]
def fmt_resource_operation(value):

View File

@@ -258,8 +258,8 @@ def main():
)
name = module.params['name']
if name == 'cgi' and _run_threaded(module):
module.fail_json(msg="Your MPM seems to be threaded. No automatic actions on module cgi possible.")
if name == 'cgi' and module.params['state'] == 'present' and _run_threaded(module):
module.fail_json(msg="Your MPM seems to be threaded, therefore enabling cgi module is not allowed.")
if not module.params['identifier']:
module.params['identifier'] = create_apache_identifier(module.params['name'])

View File

@@ -97,7 +97,7 @@ options:
type: bool
ignore_platform_reqs:
description:
- Ignore php, hhvm, lib-* and ext-* requirements and force the installation even if the local machine does not fulfill
- Ignore C(php), C(hhvm), C(lib-*) and C(ext-*) requirements and force the installation even if the local machine does not fulfill
these.
default: false
type: bool
@@ -143,6 +143,7 @@ EXAMPLES = r"""
"""
import re
import shlex
from ansible.module_utils.basic import AnsibleModule
@@ -160,7 +161,7 @@ def has_changed(string):
def get_available_options(module, command='install'):
# get all available options from a composer command using composer help to json
rc, out, err = composer_command(module, "help %s" % command, arguments="--no-interaction --format=json")
rc, out, err = composer_command(module, ["help", command], arguments=["--no-interaction", "--format=json"])
if rc != 0:
output = parse_out(err)
module.fail_json(msg=output)
@@ -169,14 +170,19 @@ def get_available_options(module, command='install'):
return command_help_json['definition']['options']
def composer_command(module, command, arguments="", options=None):
def composer_command(module, command, arguments=None, options=None):
if options is None:
options = []
if arguments is None:
arguments = []
global_command = module.params['global_command']
if not global_command:
options.extend(['--working-dir', "'%s'" % module.params['working_dir']])
if global_command:
global_arg = ["global"]
else:
global_arg = []
options.extend(['--working-dir', module.params['working_dir']])
if module.params['executable'] is None:
php_path = module.get_bin_path("php", True, ["/usr/local/bin"])
@@ -188,7 +194,7 @@ def composer_command(module, command, arguments="", options=None):
else:
composer_path = module.params['composer_executable']
cmd = [php_path, composer_path, "global" if global_command else "", command] + options + [arguments]
cmd = [php_path, composer_path] + global_arg + command + options + arguments
return module.run_command(cmd)
@@ -220,7 +226,7 @@ def main():
if re.search(r"\s", command):
module.fail_json(msg="Use the 'arguments' param for passing arguments with the 'command'")
arguments = module.params['arguments']
arguments = shlex.split(module.params['arguments'])
available_options = get_available_options(module=module, command=command)
options = []
@@ -260,7 +266,7 @@ def main():
else:
module.exit_json(skipped=True, msg="command '%s' does not support check mode, skipping" % command)
rc, out, err = composer_command(module, command, arguments, options)
rc, out, err = composer_command(module, [command], arguments, options)
if rc != 0:
output = parse_out(err)

View File

@@ -195,7 +195,7 @@ class Pids(object):
self._pids = []
def execute(self):
if self._name:
if self._name is not None:
self._pids = self._ps.get_pids_by_name(self._name)
else:
try:

View File

@@ -113,36 +113,40 @@ EXAMPLES = r"""
region: fr-par
"""
RETURNS = """
{
"scaleway_lb": {
RETURN = r"""
scaleway_lb:
description: The load-balancer object.
returned: success
type: dict
sample:
{
"backend_count": 0,
"frontend_count": 0,
"description": "Description of my load-balancer",
"id": "00000000-0000-0000-0000-000000000000",
"instances": [
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "10.0.0.1",
"region": "fr-par",
"status": "ready"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "10.0.0.2",
"region": "fr-par",
"status": "ready"
}
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "10.0.0.1",
"region": "fr-par",
"status": "ready"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "10.0.0.2",
"region": "fr-par",
"status": "ready"
}
],
"ip": [
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "192.168.0.1",
"lb_id": "00000000-0000-0000-0000-000000000000",
"region": "fr-par",
"organization_id": "00000000-0000-0000-0000-000000000000",
"reverse": ""
}
{
"id": "00000000-0000-0000-0000-000000000000",
"ip_address": "192.168.0.1",
"lb_id": "00000000-0000-0000-0000-000000000000",
"region": "fr-par",
"organization_id": "00000000-0000-0000-0000-000000000000",
"reverse": ""
}
],
"name": "lb_ansible_test",
"organization_id": "00000000-0000-0000-0000-000000000000",
@@ -152,8 +156,7 @@ RETURNS = """
"first_tag",
"second_tag"
]
}
}
}
"""
import datetime

View File

@@ -377,8 +377,8 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule, json_dict_bytes_to_unicode, missing_required_lib
from ansible.module_utils.six import iteritems, string_types
from ansible.module_utils.six.moves.collections_abc import MutableMapping
from ansible.module_utils.common.text.converters import to_bytes, to_native
from ansible.module_utils.common._collections_compat import MutableMapping
_IDENT = r"[a-zA-Z-][a-zA-Z0-9_\-\.]*"
_NSIDENT = _IDENT + "|" + _IDENT + ":" + _IDENT

View File

@@ -6,7 +6,7 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from ansible.errors import AnsibleFilterError
from ansible.module_utils.common._collections_compat import Mapping
from collections.abc import Mapping
try:
# Introduced with Data Tagging (https://github.com/ansible/ansible/pull/84621):

View File

@@ -10,7 +10,7 @@ import re
from ansible.errors import AnsibleFilterError
from ansible.module_utils.six import string_types
from ansible.module_utils.common._collections_compat import Mapping, Sequence
from collections.abc import Mapping, Sequence
def _keys_filter_params(data, matching_parameter):

View File

@@ -8,7 +8,7 @@ __metaclass__ = type
import re
from ansible.module_utils.six import binary_type, text_type
from ansible.module_utils.common._collections_compat import Mapping, Set
from collections.abc import Mapping, Set
from ansible.module_utils.common.collections import is_sequence
from ansible.utils.unsafe_proxy import (
AnsibleUnsafe,

View File

@@ -224,7 +224,7 @@ _value:
'''
from ansible.errors import AnsibleFilterError
from ansible.module_utils.common._collections_compat import Sequence
from ansible.module_utils.six.moves.collections_abc import Sequence
from ansible_collections.community.general.plugins.plugin_utils.ansible_type import _ansible_type

View File

@@ -4,8 +4,3 @@
azp/posix/2
skip/python2.7 # jc only supports python3.x
skip/freebsd13.3 # FIXME - ruyaml compilation fails
skip/freebsd14.0 # FIXME - ruyaml compilation fails
skip/freebsd14.1 # FIXME - ruyaml compilation fails
skip/freebsd14.2 # FIXME - ruyaml compilation fails
skip/freebsd14.3 # FIXME - ruyaml compilation fails

View File

@@ -17,4 +17,4 @@
- include_tasks: 'update_cache.yml'
- include_tasks: 'locally_installed_package.yml'
- include_tasks: 'reason.yml'
- include_tasks: 'yay-become.yml'
# - include_tasks: 'yay-become.yml' # TODO: re-enable once AUR git access works again

View File

@@ -5,3 +5,4 @@
keytool_package_names:
- ca-certificates-java
- openjdk-11-jre-headless

View File

@@ -11,7 +11,7 @@ import json
import pytest
from ansible.module_utils.six import string_types
from ansible.module_utils.common._collections_compat import MutableMapping
from ansible.module_utils.six.moves.collections_abc import MutableMapping
from ansible_collections.community.general.plugins.module_utils import deps
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import set_module_args as _set_module_args

View File

@@ -0,0 +1,17 @@
# -*- coding: utf-8 -*-
# Author: Alexei Znamensky (russoz@gmail.com)
#
# Copyright (c) Alexei Znamensky (russoz@gmail.com)
#
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from ansible_collections.community.general.plugins.modules import composer
from .uthelper import UTHelper, RunCommandMock
UTHelper.from_module(composer, __name__, mocks=[RunCommandMock])

View File

@@ -0,0 +1,27 @@
# -*- coding: utf-8 -*-
# Copyright (c) Alexei Znamensky (russoz@gmail.com)
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
---
anchors:
environ_true: &env-def-true {environ_update: {LANGUAGE: C, LC_ALL: C}, check_rc: true}
environ_false: &env-def-false {environ_update: {LANGUAGE: C, LC_ALL: C}, check_rc: false}
test_cases:
- id: composer
input:
command: install
working_dir: "/var/www/foo"
output:
changed: true
mocks:
run_command:
- command: ["/testbin/php", "/testbin/composer", "help", "install", "--working-dir", "/var/www/foo", "--no-interaction", "--format=json"]
rc: 0
out: |
{"definition": {"options": ["a", "b", "c"]}}
err: ''
- command: ["/testbin/php", "/testbin/composer", "install", "--working-dir", "/var/www/foo"]
rc: 0
out: ''
err: ''

View File

@@ -10,7 +10,7 @@ import json
from collections import OrderedDict
from ansible_collections.community.general.plugins.modules.jenkins_plugin import JenkinsPlugin
from ansible.module_utils.common._collections_compat import Mapping
from ansible.module_utils.six.moves.collections_abc import Mapping
from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import (
MagicMock,
patch,

View File

@@ -57,6 +57,8 @@ test_cases:
name: virtual-ip
resource_type:
resource_name: IPaddr2
resource_standard: ocf
resource_provider: heartbeat
resource_option:
- "ip=[192.168.2.1]"
resource_operation:
@@ -98,10 +100,10 @@ test_cases:
dc-version=2.1.9-1.fc41-7188dbf
have-watchdog=false
err: ""
- command: [/testbin/pcs, resource, create, virtual-ip, IPaddr2, "ip=[192.168.2.1]", op, start, timeout=1200, op, stop, timeout=1200, op, monitor, timeout=1200, meta, test_meta1=123, meta, test_meta2=456, --group, test_group, --wait=200]
- command: [/testbin/pcs, resource, create, virtual-ip, ocf:heartbeat:IPaddr2, "ip=[192.168.2.1]", op, start, timeout=1200, op, stop, timeout=1200, op, monitor, timeout=1200, meta, test_meta1=123, meta, test_meta2=456, --group, test_group, --wait=200]
environ: *env-def
rc: 0
out: "Assumed agent name 'ocf:heartbeat:IPaddr2' (deduced from 'IPAddr2')"
out: "Assumed agent name 'ocf:heartbeat:IPaddr2'"
err: ""
- command: [/testbin/pcs, resource, status, virtual-ip]
environ: *env-def

View File

@@ -253,7 +253,7 @@ class RunCommandMock(TestCaseMock):
def check(self, test_case, results):
call_args_list = [(item[0][0], item[1]) for item in self.mock_run_cmd.call_args_list]
expected_call_args_list = [(item['command'], item['environ']) for item in self.mock_specs]
expected_call_args_list = [(item['command'], item.get('environ', {})) for item in self.mock_specs]
print("call args list =\n%s" % call_args_list)
print("expected args list =\n%s" % expected_call_args_list)