Compare commits

..

No commits in common. "rawhide" and "f33" have entirely different histories.

21 changed files with 750 additions and 579 deletions

24
.coveragerc Normal file
View file

@ -0,0 +1,24 @@
# This configuration file is used for manual execution of coverage
# as well as for tests run through ansible-test.
[run]
branch = True
# Enable concurrency. This also enables parallel mode, which results in
# multiple coverage files being created. Concurrency allows us to collect
# results from multiple tests simultaneously, as well as supporting multiple
# test runs, such as from integration tests.
concurrency = multiprocessing
parallel = True
# When running tests through ansible-test, this option is overridden by
# the COVERAGE_FILE environment variable. This option is present for
# convenience when running coverage manually from this directory.
data_file = test/results/coverage/coverage
# Don't collect or report code coverage from files matching these patterns.
omit =
*/python*/dist-packages/*
*/python*/site-packages/*
*/python*/distutils
*/pytest

View file

@ -1 +0,0 @@
1

115
.gitignore vendored
View file

@ -1,2 +1,113 @@
/ansible-*.tar.gz
/ansible-*/
/ansible-1.5.3.tar.gz
/ansible-1.5.4.tar.gz
/ansible-1.5.5.tar.gz
/ansible-1.6.tar.gz
/ansible-1.6.1.tar.gz
/ansible-1.6.2.tar.gz
/ansible-1.6.3.tar.gz
/ansible-1.6.4.tar.gz
/ansible-1.6.5.tar.gz
/ansible-1.6.6.tar.gz
/ansible-1.6.7.tar.gz
/ansible-1.6.8.tar.gz
/ansible-1.6.9.tar.gz
/ansible-1.6.10.tar.gz
/ansible-1.7.tar.gz
/ansible-1.7.1.tar.gz
/ansible-1.7.2.tar.gz
/ansible-1.8.tar.gz
/ansible-1.8.1.tar.gz
/ansible-1.8.2.tar.gz
/ansible-1.8.3.tar.gz
/ansible-1.8.4.tar.gz
/ansible-1.9.0.tar.gz
/ansible-1.9.0.1.tar.gz
/ansible-1.9.1.tar.gz
/ansible-1.9.2.tar.gz
/ansible-1.9.3.tar.gz
/ansible-1.9.4.tar.gz
/ansible-2.0.0.1.tar.gz
/ansible-unittests.tar.xz
/ansible-2.0.0.2.tar.gz
/ansible-2.0.1.0.tar.gz
/ansible-unittests-2.0.1.0.tar.xz
/ansible-unittests-2.0.2.0.tar.xz
/ansible-2.0.2.0.tar.gz
/ansible-unittests-2.1.0.0.tar.xz
/ansible-2.1.0.0.tar.gz
/ansible-unittests-2.1.1.0.tar.xz
/ansible-2.1.1.0.tar.gz
/ansible-2.1.2.0.tar.gz
/ansible-unittests-2.1.2.0.tar.xz
/ansible-unittests-2.2.0.0.tar.xz
/ansible-2.2.0.0.tar.gz
/ansible-unittests-2.2.1.0.tar.xz
/ansible-2.2.1.0.tar.gz
/ansible-2.2.2.0-0.1.rc1.tar.gz
/ansible-unittests-2.2.2.0.tar.xz
/ansible-2.2.2.0.tar.gz
/ansible-2.3.0.0.tar.gz
/ansible-2.3.1.0.tar.gz
/ansible-2.3.2.0.tar.gz
/ansible-2.4.0.0.tar.gz
/ansible-2.4.1.0.tar.gz
/ansible-2.4.2.0.tar.gz
/ansible-2.4.3.0.tar.gz
/ansible-2.5.0.tar.gz
/ansible-2.5.1.tar.gz
/ansible-2.5.2.tar.gz
/ansible-2.5.3.tar.gz
/ansible-2.5.5.tar.gz
/ansible-2.6.0.tar.gz
/ansible-2.6.1.tar.gz
/ansible-2.6.2.tar.gz
/ansible-2.6.3.tar.gz
/ansible-2.6.4.tar.gz
/ansible-2.6.5.tar.gz
/ansible-2.7.0.tar.gz
/ansible-2.7.1.tar.gz
/ansible-2.7.2.tar.gz
/ansible-2.7.3.tar.gz
/ansible-2.7.4.tar.gz
/ansible-2.7.5.tar.gz
/ansible-2.7.6.tar.gz
/ansible-2.7.7.tar.gz
/ansible-2.7.8.tar.gz
/ansible-2.7.9.tar.gz
/ansible-2.7.10.tar.gz
/ansible-2.8.0b1.tar.gz
/ansible-2.8.0rc1.tar.gz
/ansible-2.8.0rc3.tar.gz
/ansible-2.8.0.tar.gz
/ansible-2.8.1.tar.gz
/ansible-2.8.2.tar.gz
/ansible-2.8.3.tar.gz
/ansible-2.8.4.tar.gz
/ansible-2.8.5.tar.gz
/ansible-2.8.6.tar.gz
/ansible-2.9.0.tar.gz
/ansible-2.9.1.tar.gz
/ansible-2.9.2.tar.gz
/ansible-2.9.3.tar.gz
/ansible-2.9.4.tar.gz
/ansible-2.9.5.tar.gz
/ansible-2.9.6.tar.gz
/ansible-2.9.7.tar.gz
/ansible-2.9.9.tar.gz
/ansible-2.9.10.tar.gz
/ansible-2.9.11.tar.gz
/ansible-2.9.12.tar.gz
/ansible-2.9.13.tar.gz
/ansible-2.9.14.tar.gz
/ansible-2.9.15.tar.gz
/ansible-2.9.16.tar.gz
/ansible-2.9.17.tar.gz
/ansible-2.9.18.tar.gz
/ansible-2.9.20.tar.gz
/ansible-2.9.21.tar.gz
/ansible-2.9.22.tar.gz
/ansible-2.9.23.tar.gz
/ansible-2.9.24.tar.gz
/ansible-2.9.25.tar.gz
/ansible-2.9.26.tar.gz
/ansible-2.9.27.tar.gz

View file

@ -1,33 +0,0 @@
# See the documentation for more information:
# https://packit.dev/docs/configuration/
upstream_project_url: https://github.com/ansible-community/ansible-build-data
issue_repository: https://pagure.io/ansible-packit-issues
create_sync_note: false
upstream_tag_include: "11"
jobs:
- job: pull_from_upstream
trigger: release
dist_git_branches:
rawhide:
fast_forward_merge_into:
- fedora-43
- fedora-42
- job: koji_build
trigger: commit
dist_git_branches:
- rawhide
- fedora-43
- fedora-42
sidetag_group: "ansible"
dependencies:
- ansible-core
- job: bodhi_update
trigger: commit
dist_git_branches:
- rawhide
- fedora-43
- fedora-42
dependencies:
- ansible-core
sidetag_group: "ansible"

View file

@ -0,0 +1,76 @@
diff --color -Nur ansible.2.9.22.orig/lib/ansible/modules/system/hostname.py ansible-2.9.22/lib/ansible/modules/system/hostname.py
--- ansible.2.9.22.orig/lib/ansible/modules/system/hostname.py 2021-05-24 14:18:02.000000000 -0700
+++ ansible-2.9.22/lib/ansible/modules/system/hostname.py 2021-06-19 10:09:53.078883364 -0700
@@ -782,6 +782,10 @@
distribution = 'Neon'
strategy_class = DebianStrategy
+class RockyLinuxHostname(Hostname):
+ platform = 'Linux'
+ distribution = 'Rocky'
+ strategy_class = SystemdStrategy
def main():
module = AnsibleModule(
diff --color -Nur ansible.2.9.22.orig/lib/ansible/module_utils/facts/system/distribution.py ansible-2.9.22/lib/ansible/module_utils/facts/system/distribution.py
--- ansible.2.9.22.orig/lib/ansible/module_utils/facts/system/distribution.py 2021-05-24 14:18:01.000000000 -0700
+++ ansible-2.9.22/lib/ansible/module_utils/facts/system/distribution.py 2021-06-19 10:09:38.680877684 -0700
@@ -467,7 +467,7 @@
OS_FAMILY_MAP = {'RedHat': ['RedHat', 'Fedora', 'CentOS', 'Scientific', 'SLC',
'Ascendos', 'CloudLinux', 'PSBM', 'OracleLinux', 'OVS',
'OEL', 'Amazon', 'Virtuozzo', 'XenServer', 'Alibaba',
- 'AlmaLinux'],
+ 'AlmaLinux', 'Rocky'],
'Debian': ['Debian', 'Ubuntu', 'Raspbian', 'Neon', 'KDE neon',
'Linux Mint', 'SteamOS', 'Devuan', 'Kali', 'Cumulus Linux'],
'Suse': ['SuSE', 'SLES', 'SLED', 'openSUSE', 'openSUSE Tumbleweed',
diff --color -Nur ansible.2.9.22.orig/test/units/module_utils/facts/system/distribution/fixtures/rockylinux_8_3.json ansible-2.9.22/test/units/module_utils/facts/system/distribution/fixtures/rockylinux_8_3.json
--- ansible.2.9.22.orig/test/units/module_utils/facts/system/distribution/fixtures/rockylinux_8_3.json 1969-12-31 16:00:00.000000000 -0800
+++ ansible-2.9.22/test/units/module_utils/facts/system/distribution/fixtures/rockylinux_8_3.json 2021-06-19 10:12:39.019948830 -0700
@@ -0,0 +1,46 @@
+{
+ "name": "Rocky 8.3",
+ "distro": {
+ "codename": "",
+ "id": "rocky",
+ "name": "Rocky Linux",
+ "version": "8.3",
+ "version_best": "8.3",
+ "lsb_release_info": {},
+ "os_release_info": {
+ "name": "Rocky Linux",
+ "version": "8.3",
+ "id": "rocky",
+ "id_like": "rhel fedora",
+ "version_id": "8.3",
+ "platform_id": "platform:el8",
+ "pretty_name": "Rocky Linux 8.3",
+ "ansi_color": "0;31",
+ "cpe_name": "cpe:/o:rocky:rocky:8",
+ "home_url": "https://rockylinux.org/",
+ "bug_report_url": "https://bugs.rockylinux.org/",
+ "rocky_support_product": "Rocky Linux",
+ "rocky_support_product_version": "8"
+ }
+ },
+ "input": {
+ "/etc/redhat-release": "Rocky Linux release 8.3\n",
+ "/etc/system-release": "Rocky Linux release 8.3\n",
+ "/etc/rocky-release": "Rocky Linux release 8.3\n",
+ "/etc/os-release": "NAME=\"Rocky Linux\"\nVERSION=\"8.3\"\nID=\"rocky\"\nID_LIKE=\"rhel fedora\"\nVERSION_ID=\"8.3\"\nPLATFORM_ID=\"platform:el8\"\nPRETTY_NAME=\"Rocky Linux 8.3\"\nANSI_COLOR=\"0;31\"\nCPE_NAME=\"cpe:/o:rocky:rocky:8\"\nHOME_URL=\"https://rockylinux.org/\"\nBUG_REPORT_URL=\"https://bugs.rockylinux.org/\"\nROCKY_SUPPORT_PRODUCT=\"Rocky Linux\"\nROCKY_SUPPORT_PRODUCT_VERSION=\"8\"\n",
+ "/usr/lib/os-release": "NAME=\"Rocky Linux\"\nVERSION=\"8.3\"\nID=\"rocky\"\nID_LIKE=\"rhel fedora\"\nVERSION_ID=\"8.3\"\nPLATFORM_ID=\"platform:el8\"\nPRETTY_NAME=\"Rocky Linux 8.3\"\nANSI_COLOR=\"0;31\"\nCPE_NAME=\"cpe:/o:rocky:rocky:8\"\nHOME_URL=\"https://rockylinux.org/\"\nBUG_REPORT_URL=\"https://bugs.rockylinux.org/\"\nROCKY_SUPPORT_PRODUCT=\"Rocky Linux\"\nROCKY_SUPPORT_PRODUCT_VERSION=\"8\"\n"
+ },
+ "platform.dist": [
+ "rocky",
+ "8.3",
+ ""
+ ],
+ "result": {
+ "distribution": "Rocky",
+ "distribution_version": "8.3",
+ "distribution_release": "NA",
+ "distribution_major_version": "8",
+ "os_family": "RedHat"
+ },
+ "platform.release": "4.18.0-240.22.1.el8.x86_64"
+}

View file

@ -0,0 +1,12 @@
diff --color -Nur ansible-2.9.23.orig/docs/docsite/_extensions/pygments_lexer.py ansible-2.9.23/docs/docsite/_extensions/pygments_lexer.py
--- ansible-2.9.23.orig/docs/docsite/_extensions/pygments_lexer.py 2021-06-21 23:04:48.000000000 -0700
+++ ansible-2.9.23/docs/docsite/_extensions/pygments_lexer.py 2021-07-10 12:33:05.790899630 -0700
@@ -178,7 +178,7 @@
See http://www.sphinx-doc.org/en/stable/extdev/index.html#dev-extensions.
"""
for lexer in [
- AnsibleOutputLexer(startinline=True)
+ AnsibleOutputLexer
]:
app.add_lexer(lexer.name, lexer)
for alias in lexer.aliases:

View file

@ -0,0 +1,15 @@
diff --color -Nur ansible-2.9.27.orig/test/units/module_utils/acme/fixtures/csr_1.pem ansible-2.9.27/test/units/module_utils/acme/fixtures/csr_1.pem
--- ansible-2.9.27.orig/test/units/module_utils/acme/fixtures/csr_1.pem 2021-10-11 08:18:57.217846900 -0700
+++ ansible-2.9.27/test/units/module_utils/acme/fixtures/csr_1.pem 2021-10-26 15:19:37.479752918 -0700
@@ -1,4 +1,4 @@
------BEGIN NEW CERTIFICATE REQUEST-----
+-----BEGIN CERTIFICATE REQUEST-----
MIIBJTCBzQIBADAWMRQwEgYDVQQDEwthbnNpYmxlLmNvbTBZMBMGByqGSM49AgEG
CCqGSM49AwEHA0IABACc9MgAFwMBJjoU0ZI18cIHnW1juoKG2DN5VrM60uvBvEEs
4V0egJkNyM2Q4pp001zu14VcpQ0/Ei8xOOPxKZugVTBTBgkqhkiG9w0BCQ4xRjBE
@@ -6,4 +6,4 @@
AjAAMA8GA1UdDwEB/wQFAwMHgAAwCgYIKoZIzj0EAwIDRwAwRAIgcDyoRmwFVBDl
FvbFZtiSd5wmJU1ltM6JtcfnLWnjY54CICruOByrropFUkOKKb4xXOYsgaDT93Wr
URnCJfTLr2T3
------END NEW CERTIFICATE REQUEST-----
+-----END CERTIFICATE REQUEST-----

View file

@ -0,0 +1,81 @@
diff --color -Nur ansible-2.9.27.orig/test/units/modules/cloud/openstack/test_os_server.py ansible-2.9.27/test/units/modules/cloud/openstack/test_os_server.py
--- ansible-2.9.27.orig/test/units/modules/cloud/openstack/test_os_server.py 2021-10-11 08:18:57.290846800 -0700
+++ ansible-2.9.27/test/units/modules/cloud/openstack/test_os_server.py 2021-10-26 14:36:44.086550302 -0700
@@ -22,7 +22,7 @@
module.'''
doc = inspect.getdoc(func)
- cfg = yaml.load(doc)
+ cfg = yaml.load(doc, Loader=yaml.CLoader)
for task in cfg:
for module, params in task.items():
diff --color -Nur ansible-2.9.27.orig/test/units/modules/remote_management/oneview/test_oneview_ethernet_network.py ansible-2.9.27/test/units/modules/remote_management/oneview/test_oneview_ethernet_network.py
--- ansible-2.9.27.orig/test/units/modules/remote_management/oneview/test_oneview_ethernet_network.py 2021-10-11 08:18:57.447847000 -0700
+++ ansible-2.9.27/test/units/modules/remote_management/oneview/test_oneview_ethernet_network.py 2021-10-26 14:37:25.647363390 -0700
@@ -141,7 +141,7 @@
self.resource.update.return_value = data_merged
self.mock_ov_client.connection_templates.get.return_value = {"uri": "uri"}
- self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES)
+ self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES, Loader=yaml.CLoader)
EthernetNetworkModule().run()
@@ -155,7 +155,7 @@
self.resource.get_by.return_value = [DICT_PARAMS_WITH_CHANGES]
self.mock_ov_client.connection_templates.get.return_value = {"uri": "uri"}
- self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES)
+ self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES, Loader=yaml.CLoader)
EthernetNetworkModule().run()
@@ -174,7 +174,7 @@
self.mock_ov_client.connection_templates.get.return_value = {
"bandwidth": DICT_PARAMS_WITH_CHANGES['bandwidth']}
- self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES)
+ self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES, Loader=yaml.CLoader)
EthernetNetworkModule().run()
@@ -191,7 +191,7 @@
self.resource.get_by.return_value = [DEFAULT_ENET_TEMPLATE]
self.resource.update.return_value = data_merged
- self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES)
+ self.mock_ansible_module.params = yaml.load(YAML_PARAMS_WITH_CHANGES, Loader=yaml.CLoader)
EthernetNetworkModule().run()
@@ -329,7 +329,7 @@
"max": 1
}}
- self.mock_ansible_module.params = yaml.load(YAML_RESET_CONNECTION_TEMPLATE)
+ self.mock_ansible_module.params = yaml.load(YAML_RESET_CONNECTION_TEMPLATE, Loader=yaml.CLoader)
EthernetNetworkModule().run()
@@ -340,7 +340,7 @@
def test_should_fail_when_reset_not_existing_ethernet_network(self):
self.resource.get_by.return_value = [None]
- self.mock_ansible_module.params = yaml.load(YAML_RESET_CONNECTION_TEMPLATE)
+ self.mock_ansible_module.params = yaml.load(YAML_RESET_CONNECTION_TEMPLATE, Loader=yaml.CLoader)
EthernetNetworkModule().run()
diff --color -Nur ansible-2.9.27.orig/test/units/plugins/action/test_synchronize.py ansible-2.9.27/test/units/plugins/action/test_synchronize.py
--- ansible-2.9.27.orig/test/units/plugins/action/test_synchronize.py 2021-10-11 08:18:57.476847000 -0700
+++ ansible-2.9.27/test/units/plugins/action/test_synchronize.py 2021-10-26 15:22:02.968085259 -0700
@@ -121,7 +121,7 @@
metapath = os.path.join(fixturepath, 'meta.yaml')
with open(metapath, 'rb') as f:
fdata = f.read()
- test_meta = yaml.load(fdata)
+ test_meta = yaml.load(fdata, Loader=yaml.CLoader)
# load initial play context vars
if '_play_context' in test_meta:

View file

@ -0,0 +1,78 @@
diff -Nur ansible-2.9.6.orig/test/units/galaxy/test_collection_install.py ansible-2.9.6/test/units/galaxy/test_collection_install.py
--- ansible-2.9.6.orig/test/units/galaxy/test_collection_install.py 2020-03-04 21:40:01.000000000 -0800
+++ ansible-2.9.6/test/units/galaxy/test_collection_install.py 2020-03-06 13:35:48.489822740 -0800
@@ -204,40 +204,40 @@
collection.CollectionRequirement.from_path(collection_artifact[0], True)
-def test_build_requirement_from_path_no_version(collection_artifact, monkeypatch):
- manifest_path = os.path.join(collection_artifact[0], b'MANIFEST.json')
- manifest_value = json.dumps({
- 'collection_info': {
- 'namespace': 'namespace',
- 'name': 'name',
- 'version': '',
- 'dependencies': {}
- }
- })
- with open(manifest_path, 'wb') as manifest_obj:
- manifest_obj.write(to_bytes(manifest_value))
-
- mock_display = MagicMock()
- monkeypatch.setattr(Display, 'display', mock_display)
-
- actual = collection.CollectionRequirement.from_path(collection_artifact[0], True)
-
- # While the folder name suggests a different collection, we treat MANIFEST.json as the source of truth.
- assert actual.namespace == u'namespace'
- assert actual.name == u'name'
- assert actual.b_path == collection_artifact[0]
- assert actual.api is None
- assert actual.skip is True
- assert actual.versions == set(['*'])
- assert actual.latest_version == u'*'
- assert actual.dependencies == {}
-
- assert mock_display.call_count == 1
-
- actual_warn = ' '.join(mock_display.mock_calls[0][1][0].split('\n'))
- expected_warn = "Collection at '%s' does not have a valid version set, falling back to '*'. Found version: ''" \
- % to_text(collection_artifact[0])
- assert expected_warn in actual_warn
+#def test_build_requirement_from_path_no_version(collection_artifact, monkeypatch):
+# manifest_path = os.path.join(collection_artifact[0], b'MANIFEST.json')
+# manifest_value = json.dumps({
+# 'collection_info': {
+# 'namespace': 'namespace',
+# 'name': 'name',
+# 'version': '',
+# 'dependencies': {}
+# }
+# })
+# with open(manifest_path, 'wb') as manifest_obj:
+# manifest_obj.write(to_bytes(manifest_value))
+#
+# mock_display = MagicMock()
+# monkeypatch.setattr(Display, 'display', mock_display)
+#
+# actual = collection.CollectionRequirement.from_path(collection_artifact[0], True)
+#
+# # While the folder name suggests a different collection, we treat MANIFEST.json as the source of truth.
+# assert actual.namespace == u'namespace'
+# assert actual.name == u'name'
+# assert actual.b_path == collection_artifact[0]
+# assert actual.api is None
+# assert actual.skip is True
+# assert actual.versions == set(['*'])
+# assert actual.latest_version == u'*'
+# assert actual.dependencies == {}
+#
+# assert mock_display.call_count == 1
+#
+# actual_warn = ' '.join(mock_display.mock_calls[0][1][0].split('\n'))
+# expected_warn = "Collection at '%s' does not have a valid version set, falling back to '*'. Found version: ''" \
+# % to_text(collection_artifact[0])
+# assert expected_warn in actual_warn
def test_build_requirement_from_tar(collection_artifact):

46
ansible-generator Executable file
View file

@ -0,0 +1,46 @@
#!/usr/bin/python3
import argparse
import json
import re
import sys
def main():
parser = argparse.ArgumentParser()
group = parser.add_mutually_exclusive_group(required=True)
group.add_argument(
"-P", "--provides", action="store_const", const="provides", dest="action"
)
group.add_argument(
"-R", "--requires", action="store_const", const="requires", dest="action"
)
args = parser.parse_args()
files = sys.stdin.read().splitlines()
for f in files:
with open(f, "r") as fobj:
info = json.load(fobj)["collection_info"]
if args.action == "provides":
print(
f"ansible-collection({info['namespace']}.{info['name']}) = {info['version']}"
)
if args.action == "requires":
print("(ansible >= 2.9.0 or ansible-base > 2.10.0)")
for dep, req in info.get("dependencies", {}).items():
print(f"ansible-collection({dep})", end="")
if req == "*":
print()
continue
m = re.match(r"^>=(\d+\.\d+\.\d+)$", req)
if m:
print(f" >= {m.group(1)}")
continue
raise NotImplementedError(
"Generation of dependencies different than '*' or '>=' is not supported yet"
)
if __name__ == "__main__":
main()

View file

@ -1,46 +0,0 @@
#!/usr/bin/bash -x
# SPDX-License-Identifier: MIT
# Copyright (C) Fedora Project Authors
# License Text: https://spdx.org/licenses/MIT.txt
set -euo pipefail
ansible_licensedir="${1}"
ansible_docdir="${2}"
# Install docs and licenses
mkdir -p "${ansible_licensedir}" "${ansible_docdir}"
# This finds the license file for each collection and moves it to
# `${ansible_licensedir}`
for f in $(find -mindepth 3 -iname 'LICENSES' -type d -printf '%P\n')
do
dirname="$(dirname "${ansible_licensedir}/${f}")"
mkdir -p "${dirname}"
mv "${f}" "${ansible_licensedir}/${f}"
done
for f in $(
find . -mindepth 3 -type f \
\( -iname '*LICENSE*' -o -iname '*COPYING*' \) \
-not -name '*.py' -not -name '*.pyc' \
-not -name '*.license' -not -name '*.yaml' -not -name '*.yml' \
-not -name '*.json' \
-printf '%P\n' \
| grep -vE '/docs/[^/]+_module\.rst$'
)
do
dirname="$(dirname "${ansible_licensedir}/${f}")"
mkdir -p "${dirname}"
mv "${f}" "${dirname}"
done
# This does the same thing, but for READMEs.
for f in $(find . -mindepth 3 -type f -name 'README*' -printf '%P\n')
do
dirname="$(dirname "${ansible_docdir}/${f}")"
mkdir -p "${dirname}"
mv "${f}" "${dirname}"
done

View file

@ -1,69 +0,0 @@
#!/usr/bin/bash -x
# SPDX-License-Identifier: MIT
# Copyright (C) Fedora Project Authors
# License Text: https://spdx.org/licenses/MIT.txt
set -euo pipefail
# Fix wrong-script-end-of-line-encoding in azure.azcollection
find ansible_collections/azure/azcollection -type f -print -exec dos2unix -k '{}' \;
# Remove unnecessary files and directories included in the Ansible collection release tarballs
# Tracked upstream in part by: https://github.com/ansible-community/community-topics/issues/29
echo "[START] Delete unnecessary files and directories"
# Collection tarballs contain a lot of hidden files and directories
hidden_pattern=".*\.(DS_Store|all-contributorsrc|ansible-lint|azure-pipelines|circleci|codeclimate.yml|flake8|galaxy_install_info|gitattributes|github|gitignore|gitkeep|gitlab-ci.yml|idea|keep|mypy_cache|nojekyll|orig|plugin-cache.yaml|pre-commit-config.yaml|project|pydevproject|pytest_cache|pytest_cache|readthedocs.yml|settings|swp|travis.yml|vscode|yamllint|yamllint.yaml|zuul.d|zuul.yaml|rstcheck.cfg|placeholder)$"
find ansible_collections -depth -regextype posix-egrep -regex "${hidden_pattern}" -print -exec rm -r {} \;
# Not needed for runtime
rm -rv ansible_collections/cisco/meraki/scripts/
rm -rv ansible_collections/community/grafana/hacking/
rm -rv ansible_collections/community/okd/ci/
rm -rv ansible_collections/community/vmware/tools/
rm -rv ansible_collections/cyberark/conjur/roles/conjur_host_identity/tests/
rm -rv ansible_collections/google/cloud/scripts/
rm -rv ansible_collections/google/cloud/test-fixtures/
rm -rv ansible_collections/grafana/grafana/tools/
rm -rv ansible_collections/hetzner/hcloud/scripts/
rm -rv ansible_collections/netbox/netbox/hacking/
rm -v ansible_collections/community/mysql/run_all_tests.py
rm -v ansible_collections/dellemc/enterprise_sonic/rebuild.sh
rm -v ansible_collections/ovirt/ovirt/build.sh
# rpmlint W: pem-certificate
find ansible_collections/cyberark/conjur -type f -name "*.pem" -print -delete
# rpmlint E: zero-length
find -type f -name "*requirements.txt" -size 0 -print -delete
rm -v ansible_collections/community/zabbix/roles/zabbix_agent/files/win_sample/doSomething.ps1
rm -v ansible_collections/community/docker/meta/ee-bindep.txt
echo "[END] Delete unnecessary files and directories"
###
# Fix various shebang related issues to appease brp-managle-shebangs
###
find ansible_collections/community/mongodb/roles/*/{files,templates} -type f '!' -executable -name '*.sh*' \
-print -exec chmod a+x '{}' \;
# ansible_collections/lowlydba/sqlserver thought it was a good idea to make
# *every* single file, in its repository executable, including .md, .yml, and
# .rst. :facepalm:
#
# TODO: File issue upstream
find ansible_collections/lowlydba/sqlserver/ -executable -type f -print -exec chmod a-x '{}' \;
# Remove shebangs instead of hardocding to %%__python3 to avoid unexpected issues
# from https://github.com/ansible/ansible/commit/9142be2f6cabbe6597c9254c5bb9186d17036d55.
# Upstream, ansible-core has also removed shebangs from its modules.
#
# XXX: Print out the files before they're replaced
find ansible_collections -type f ! -executable -name '*.py' | tee non_exec
echo ansible_collections/community/sap_libs/plugins/module_utils/swpm2_parameters_inifile_generate.py >> non_exec
# xargs is noticably faster than find -exec, because it spawns one sed process
# instead of ~13 thousand!
xargs -a non_exec -d'\n' sed -i -e '1{\@^#!.*@d}'

3
ansible.attr Normal file
View file

@ -0,0 +1,3 @@
%__ansible_provides %{_rpmconfigdir}/ansible-generator --provides
%__ansible_requires %{_rpmconfigdir}/ansible-generator --requires
%__ansible_path ^%{_datadir}/ansible/collections/ansible_collections/[^/]+/[^/]+/MANIFEST.json$

View file

@ -1,9 +0,0 @@
addFilter("W: files-duplicate")
addFilter("E: files-duplicated-waste")
addFilter("W: name-repeated-in-summary")
addFilter("W: cross-directory-hard-link")
# Roles' files and templates should not be mangled
addFilter(r"E: env-script-interpreter.*ansible_collections/[^/]+/[^/]+/roles/[^/]+/(files|templates)/")
addFilter(r"E: non-executable-script.*ansible_collections/[^/]+/[^/]+/roles/[^/]+/(files|templates)/")
addFilter("W: no-manual-page-for-binary ansible-community")
addFilter(r"E: zero-length")

View file

@ -1,78 +1,129 @@
# SPDX-License-Identifier: MIT
# Copyright (C) Fedora Project Authors
# License Text: https://spdx.org/licenses/MIT.html
# Note to maintainers: main and all fedora branches can be merged.
# epel8 and epel7 and should be updated seperately.
# Compatibility #
#############################################################################
# This specfile should remain compatible with EPEL 9 and stable Fedoras. #
# The EPEL 8 specfile is separately maintained, #
# but the ansible-prep.sh and ansible-install-license.sh scripts are shared #
# across branches. #
#############################################################################
# in Fedora and EPEL8 build with docs and tests by default
%global with_docs 1
# TODO: Re-enable docs and tests once possible
%bcond docs 0
%bcond tests 0
# disable the python -s shbang flag as we want to be able to find non system modules
# NB: We cannot use https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_py3_shebang_S on RHEL 9.
%global py3_shebang_flags %(echo %{py3_shebang_flags} | sed 's|s||')
# Roles' files and templates should not be mangled.
# These files are installed on remote systems which may or may not have the
# same filesystem layout as Fedora.
%global __brp_mangle_shebangs_exclude_from ^%{python3_sitelib}/ansible_collections/[^/]+/[^/]+/roles/[^/]+/(files|templates)/.*$
%global __requires_exclude_from %{?__requires_exclude_from:%__requires_exclude_from|}%{__brp_mangle_shebangs_exclude_from}
%if 0%{?rhel} >= 8
# ansible-core package is built against Python 3.11 in RHEL 8 and RHEL 9 which
# is not the default version.
%global python3_pkgversion 3.11
# Disable tests on f29/f30 and epel8 for now.
# epel8 is missing 2 required packages.
# fedora29 and fedora30 have too old pytest
%if 0%{?fedora} < 31 || 0%{?rhel} >= 8
%global with_tests 0
%else
%global with_tests 1
%endif
Name: ansible
Summary: Curated set of Ansible collections included in addition to ansible-core
Version: 13.1.0
%global uversion %{version_no_tilde %{quote:%nil}}
Release: 2%{?dist}
Name: ansible
Summary: SSH-based configuration management, deployment, and task execution system
Version: 2.9.27
Release: 1%{?dist}
# In addition to GPL-3.0-or-later, the following licenses apply.
# License text that solely exists in file headers were not considered.
# Instead, the overall license was determined by searching for license files
# This is the only the practical way to handle license scanning for a project
# of this size.
# All collections must be primarily licensed under GPL-3.0-or-later, so top
# level license files are excluded.
# find /usr/share/licenses/ansible -type f | grep -vEe '(COPYING|LICENSE)(\.(txt|md))?$' -e 'GPL' | xargs -n1 basename | sort -u
License: GPLv3+
Source0: https://releases.ansible.com/ansible/%{name}-%{version}.tar.gz
Source1: ansible.attr
Source2: ansible-generator
Source3: macros.ansible
Url: http://ansible.com
BuildArch: noarch
# add patch for Rocky linux: rhbz#1968728
Patch1: ansible-2.9.22-rocky.patch
# Disable failing test
Patch2: ansible-2.9.6-disable-test_build_requirement_from_path_no_version.patch
# Fix Python 3.9 compatibility
# Backported from upstream: https://github.com/ansible/ansible/pull/67891
Patch3: fix-python-3.9-compatibility.patch
# Fix to build docs with sphinx > 4.0
Patch4: ansible-2.9.23-sphinx4.patch
# compatiblity with pyyaml > 6 for some tests
Patch5: ansible-2.9.27-pyyaml-6-compat.patch
# compatibility with openssl v3
Patch6: ansible-2.9.27-openssl-3-compat.patch
# We used to have a ansible-python3 package that a number of other things
# started depending on, so we should now provide/obsolete it until they
# can all adjust to just needing ansible.
Provides: ansible-python3 = %{version}-%{release}
Obsoletes: ansible-python3 < %{version}-%{release}
# Conflict with the ansible-base package for now.
Conflicts: ansible-base > 2.10.0
# Conflict with the ansible-core package for now also.
Conflicts: ansible-core > 2.11.0
%if 0%{?with_tests}
#
# Apache-2.0.txt
# Apache-license.txt
# BSD-2-Clause.txt
# BSD-3-Clause.txt
# MIT.txt
# MPL-2.0.txt
# PSF-2.0.txt
# PSF-license.txt
License: GPL-3.0-or-later AND Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0 AND PSF-2.0
Source0: %{pypi_source %{name} %{uversion}}
Source1: ansible-prep.sh
Source2: ansible-install-licenses.sh
# For tests
#
# These two exist on both fedora and rhel8
#
BuildRequires: python3-packaging
BuildRequires: python3-pexpect
#
# These only exist on Fedora. RHEL8 will just skip tests that need them.
#
%if 0%{?fedora}
BuildRequires: python3-paramiko
BuildRequires: python3-winrm
Url: https://ansible.com
BuildArch: noarch
BuildRequires: dos2unix
BuildRequires: findutils
BuildRequires: python%{python3_pkgversion}-devel
%if %{with tests}
# TODO build-requires
BuildRequires: python3-crypto
BuildRequires: python3-pbkdf2
BuildRequires: python3-httmock
BuildRequires: python3-gitlab
BuildRequires: python3-boto3
BuildRequires: python3-botocore
BuildRequires: python3-coverage
BuildRequires: python3-passlib
%endif
%if %{with docs}
# TODO build-requires
%endif
# For Docs/tests
BuildRequires: git-core
BuildRequires: openssl
%if 0%{?with_docs}
BuildRequires: python3-sphinx
BuildRequires: python3-sphinx-theme-alabaster
BuildRequires: python3-sphinx-notfound-page
BuildRequires: asciidoc
BuildRequires: python3-straight-plugin
%endif
BuildRequires: python3-devel
BuildRequires: python3-setuptools
# accelerate is the only thing that makes keyczar mandatory. Since accelerate
# is deprecated, just ignore it
#BuildRequires: python-keyczar
BuildRequires: python3-six
BuildRequires: python3-nose
# We pin Pytest to version 4 for now
# as there are some test failures with
# version 5. See rhbz#1841968
BuildRequires: %{py3_dist pytest}
BuildRequires: python3-pytest-xdist
BuildRequires: python3-pytest-mock
BuildRequires: python3-requests
BuildRequires: python3-mock
BuildRequires: python3-jinja2
BuildRequires: python3-pyyaml
BuildRequires: python3-cryptography
BuildRequires: python3-pyvmomi
BuildRequires: make
# RHEL8 doesn't have python3-paramiko or python3-winrm (yet), but Fedora does
Recommends: python3-paramiko
Recommends: python3-winrm
# accelerate is the only thing that makes keyczar mandatory. Since accelerate
# is deprecated, just ignore it
#Requires: python3-keyczar
Requires: python3-setuptools
Requires: python3-six
Requires: python3-jinja2
Requires: python3-pyyaml
Requires: sshpass
# needed for json_query filter
Requires: python3-jmespath
%description
Ansible is a radically simple model-driven configuration management,
@ -81,336 +132,155 @@ over SSH and does not require any software or daemons to be installed
on remote nodes. Extension modules can be written in any language and
are transferred to managed machines automatically.
This package provides a curated set of Ansible collections included in addition
to ansible-core.
%package -n ansible-doc
Summary: Documentation for Ansible
%description -n ansible-doc
Ansible is a radically simple model-driven configuration management,
multi-node deployment, and remote task execution system. Ansible works
over SSH and does not require any software or daemons to be installed
on remote nodes. Extension modules can be written in any language and
are transferred to managed machines automatically.
This package installs extensive documentation for ansible
%package -n ansible-test
Summary: Tool for testing ansible plugin and module code
Requires: %{name} = %{version}-%{release}
%description -n ansible-test
Ansible is a radically simple model-driven configuration management,
multi-node deployment, and remote task execution system. Ansible works
over SSH and does not require any software or daemons to be installed
on remote nodes. Extension modules can be written in any language and
are transferred to managed machines automatically.
This package installs the ansible-test command for testing modules and plugins
developed for ansible.
%prep
%autosetup -N -n %{name}-%{uversion}
# Relax ansible-core dependency to avoid FTI bugs on EPEL
#
# This is necessary, because the EPEL ansible maintainers don't have control
# over ansible-core in RHEL, and it's difficult to time updates across
# repositories. I have tried to stick to upstream's version constraints, but
# that's apparently not working too well. This change gives us a grace period
# to properly release and test new ansible major versions after RHEL rebases
# ansible-core. The lower version constraints can stay in place.
sed "s|ansible-core ~=|ansible-core >=|" setup.cfg > setup.cfg.bak
# Verify
set -o pipefail
grep -B1 "ansible-core >=" setup.cfg.bak | grep -F 'install_requires ='
%if %{defined rhel}
mv setup.cfg.bak setup.cfg
%endif
# ansible-prep.sh
%{S:1}
(
mkdir licenses docs
cd ansible_collections
# ansible-license-install.sh
%{S:2} \
"$(readlink -f ../licenses)" \
"$(readlink -f ../docs)" \
)
%generate_buildrequires
%pyproject_buildrequires
%autosetup -p1
cp -a %{S:1} %{S:2} %{S:3} .
%build
%py3_shebang_fix ansible_collections
%pyproject_wheel
# Fix some files shebangs
sed -i -e 's|/usr/bin/env python|/usr/bin/python3|' test/lib/ansible_test/_data/*.py test/lib/ansible_test/_data/*/*.py test/lib/ansible_test/_data/*/*/*.py docs/bin/find-plugin-refs.py
# These we have to supress or the package will depend on /usr/bin/pwsh and not be installable.
sed -i -s 's|/usr/bin/env pwsh||' test/lib/ansible_test/_data/sanity/validate-modules/validate_modules/ps_argspec.ps1
sed -i -s 's|/usr/bin/env pwsh||' test/lib/ansible_test/_data/sanity/pslint/pslint.ps1
sed -i -s 's|/usr/bin/env pwsh||' test/lib/ansible_test/_data/requirements/sanity.ps1
# disable the python -s shbang flag as we want to be able to find non system modules
%global py3_shbang_opts %(echo %{py3_shbang_opts} | sed 's/-s//')
%py3_build
%if 0%{?with_docs}
make PYTHON=/usr/bin/python3 SPHINXBUILD=sphinx-build-3 webdocs
%else
make PYTHON=/usr/bin/python3 -Cdocs/docsite config cli keywords modules plugins testing
%endif
%install
%pyproject_install
# This adds over a minute to the build due to the size of the ansible package.
# It's better to manually specify the paths in %%files...
# %%pyproject_save_files ansible_collections
%py3_install
mkdir -p %{buildroot}%{_licensedir}/ansible %{buildroot}%{_docdir}/ansible
mv licenses %{buildroot}%{_licensedir}/ansible/ansible_collections
mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
# Create system directories that Ansible defines as default locations in
# ansible/config/base.yml
DATADIR_LOCATIONS='%{_datadir}/ansible/collections
%{_datadir}/ansible/collections/ansible_collections
%{_datadir}/ansible/plugins/doc_fragments
%{_datadir}/ansible/plugins/action
%{_datadir}/ansible/plugins/become
%{_datadir}/ansible/plugins/cache
%{_datadir}/ansible/plugins/callback
%{_datadir}/ansible/plugins/cliconf
%{_datadir}/ansible/plugins/connection
%{_datadir}/ansible/plugins/filter
%{_datadir}/ansible/plugins/httpapi
%{_datadir}/ansible/plugins/inventory
%{_datadir}/ansible/plugins/lookup
%{_datadir}/ansible/plugins/modules
%{_datadir}/ansible/plugins/module_utils
%{_datadir}/ansible/plugins/netconf
%{_datadir}/ansible/roles
%{_datadir}/ansible/plugins/strategy
%{_datadir}/ansible/plugins/terminal
%{_datadir}/ansible/plugins/test
%{_datadir}/ansible/plugins/vars'
UPSTREAM_DATADIR_LOCATIONS=$(grep -ri default lib/ansible/config/base.yml| tr ':' '\n' | grep '/usr/share/ansible')
if [ "$SYSTEM_LOCATIONS" != "$UPSTREAM_SYSTEM_LOCATIONS" ] ; then
echo "The upstream Ansible datadir locations have changed. Spec file needs to be updated"
exit 1
fi
mkdir -p $RPM_BUILD_ROOT%{_datadir}/ansible/plugins/
for location in $DATADIR_LOCATIONS ; do
mkdir $RPM_BUILD_ROOT"$location"
done
mkdir -p $RPM_BUILD_ROOT/etc/ansible/
mkdir -p $RPM_BUILD_ROOT/etc/ansible/roles/
cp examples/hosts $RPM_BUILD_ROOT/etc/ansible/
cp examples/ansible.cfg $RPM_BUILD_ROOT/etc/ansible/
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1
cp -v docs/man/man1/*.1 $RPM_BUILD_ROOT/%{_mandir}/man1/
cp -pr docs/docsite/rst .
%if 0%{?with_docs}
cp -pr docs/docsite/_build/html %{_builddir}/%{name}-%{version}/html
%endif
install -Dpm0644 -t %{buildroot}%{_fileattrsdir} ansible.attr
install -Dpm0644 -t %{buildroot}%{_rpmmacrodir} macros.ansible
install -Dpm0755 -t %{buildroot}%{_rpmconfigdir} ansible-generator
%check
%if %{with tests}
# TODO: Run tests
%if 0%{?with_tests}
ln -s /usr/bin/pytest-3 bin/pytest
pathfix.py -i %{__python3} -p test/lib/ansible_test/_data/cli/ansible_test_cli_stub.py
# This test needs a module not packaged in Fedora so disable it.
rm -f test/units/modules/cloud/cloudstack/test_cs_traffic_type.py
# These tests are failing with pytest 6
rm -f test/units/module_utils/facts/hardware/test_sunos_get_uptime_facts.py
rm -f test/units/modules/source_control/test_gitlab_runner.py
rm -f test/units/plugins/lookup/test_aws_secret.py
rm -f test/units/plugins/lookup/test_aws_ssm.py
make PYTHON=/usr/bin/python3 tests-py3
%endif
%files
%license COPYING
%license %{_licensedir}/ansible/ansible_collections/
%doc README.rst PKG-INFO porting_guide_*.rst CHANGELOG-v*.rst
%doc %{_pkgdocdir}/ansible_collections/
%{_bindir}/ansible-community
# Note (dmsimard): This ansible package installs collections to the python sitelib to mirror the UX
# when installing the ansible package from PyPi.
# This allows users to install individual collections manually with ansible-galaxy (~/.ansible/collections/ansible_collections)
# or via standalone distribution packages to datadir (/usr/share).
# Both will have precedence over the collections installed in the python sitelib.
%{python3_sitelib}/ansible_collections/
%{python3_sitelib}/ansible-%{uversion}.dist-info/
%doc README.rst PKG-INFO changelogs/CHANGELOG-v2.9.rst
%doc %{_mandir}/man1/ansible*
%config(noreplace) %{_sysconfdir}/ansible/
%{_bindir}/ansible*
%{_datadir}/ansible/
%{python3_sitelib}/ansible
%{python3_sitelib}/ansible_test
%{python3_sitelib}/*egg-info
%{_fileattrsdir}/ansible.attr
%{_rpmmacrodir}/macros.ansible
%{_rpmconfigdir}/ansible-generator
%exclude %{_bindir}/ansible-test
%exclude %{python3_sitelib}/ansible_test
%files -n ansible-doc
%doc rst
%if 0%{?with_docs}
%doc html
%endif
%files -n ansible-test
%{_bindir}/ansible-test
%{python3_sitelib}/ansible_test
%changelog
* Fri Jan 16 2026 Fedora Release Engineering <releng@fedoraproject.org> - 13.1.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild
* Tue Dec 09 2025 Maxwell G <maxwell@gtmx.me> - 13.1.0-1
- Update to 13.1.0. Fixes rhbz#2354912.
* Mon Nov 17 2025 Packit <hello@packit.dev> - 11.12.0-1
- Update to version 11.12.0
* Sat Sep 27 2025 Maxwell G <maxwell@gtmx.me> - 11.10.0-1
- Update to 11.10.0.
* Fri Sep 19 2025 Python Maint <python-maint@redhat.com> - 11.8.0-4
- Rebuilt for Python 3.14.0rc3 bytecode
* Fri Aug 15 2025 Python Maint <python-maint@redhat.com> - 11.8.0-3
- Rebuilt for Python 3.14.0rc2 bytecode
* Wed Jul 23 2025 Fedora Release Engineering <releng@fedoraproject.org> - 11.8.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
* Wed Jul 16 2025 Maxwell G <maxwell@gtmx.me> - 11.8.0-1
- Update to 11.8.0.
* Sat Jun 07 2025 Python Maint <python-maint@redhat.com> - 11.6.0-2
- Rebuilt for Python 3.14
* Sat Jun 07 2025 Maxwell G <maxwell@gtmx.me> - 11.6.0-1
- Update to 11.6.0.
* Tue Mar 25 2025 Packit <hello@packit.dev> - 11.4.0-1
- Update to version 11.4.0
- Resolves: rhbz#2354912
* Mon Mar 17 2025 Packit <hello@packit.dev> - 11.3.0-1
- Update to version 11.3.0
* Thu Jan 16 2025 Fedora Release Engineering <releng@fedoraproject.org> - 11.1.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
* Wed Dec 18 2024 Maxwell G <maxwell@gtmx.me> - 11.1.0-1
- Update to 11.1.0.
* Tue Nov 26 2024 Maxwell G <maxwell@gtmx.me> - 11.0.0-1
- Update to 11.0.0.
* Fri Oct 11 2024 Maxwell G <maxwell@gtmx.me> - 9.11.0-1
- Update to 9.11.0.
* Tue Sep 10 2024 Maxwell G <maxwell@gtmx.me> - 9.10.0-1
- Update to 9.10.0.
* Tue Aug 13 2024 Maxwell G <maxwell@gtmx.me> - 9.9.0-1
- Update to 9.9.0.
* Fri Jul 19 2024 Maxwell G <maxwell@gtmx.me> - 9.8.0-1
- Update to 9.8.0.
* Wed Jul 17 2024 Fedora Release Engineering <releng@fedoraproject.org> - 9.7.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Sun Jun 23 2024 Maxwell G <maxwell@gtmx.me> - 9.7.0-1
- Update to 9.7.0.
* Sun Jun 09 2024 Maxwell G <maxwell@gtmx.me> - 9.6.1-1
- Update to 8.6.1.
* Sun Jun 09 2024 Python Maint <python-maint@redhat.com> - 9.6.0-2
- Rebuilt for Python 3.13
* Tue Jun 04 2024 Maxwell G <maxwell@gtmx.me> - 9.6.0-1
- Update to 9.6.0.
* Thu May 02 2024 Maxwell G <maxwell@gtmx.me> - 9.5.1-1
- Update to 9.5.1.
* Fri Mar 29 2024 Maxwell G <maxwell@gtmx.me> - 9.4.0-1
- Update to 9.4.0.
* Sat Mar 02 2024 Maxwell G <maxwell@gtmx.me> - 9.3.0-1
- Update to 9.3.0.
- Backport "podman pod info" patch to containers.podman
* Thu Feb 01 2024 Maxwell G <maxwell@gtmx.me> - 9.2.0-1
- Update to 9.2.0.
* Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 9.1.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 9.1.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Wed Dec 06 2023 Maxwell G <maxwell@gtmx.me> - 9.1.0-1
- Update to 9.1.0.
* Tue Nov 21 2023 Maxwell G <maxwell@gtmx.me> - 9.0.1-1
- Update to 9.0.1.
* Thu Oct 19 2023 Maxwell G <maxwell@gtmx.me> - 9.0.0~a3-1
- Update to 9.0.0~a3.
* Thu Oct 12 2023 Maxwell G <maxwell@gtmx.me> - 9.0.0~a2-1
- Update to 9.0.0~a2.
* Thu Sep 28 2023 Maxwell G <maxwell@gtmx.me> - 9.0.0~a1-1
- Update to 9.0.0~a1.
* Tue Sep 12 2023 Maxwell G <maxwell@gtmx.me> - 8.4.0-1
- Update to 8.4.0.
* Thu Aug 17 2023 Maxwell G <maxwell@gtmx.me> - 8.3.0-1
- Update to 8.3.0.
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 8.1.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Mon Jul 03 2023 Maxwell G <maxwell@gtmx.me> - 8.1.0-2
- Rebuilt for Python 3.12
* Thu Jun 22 2023 Maxwell G <maxwell@gtmx.me> - 8.1.0-1
- Update to 8.1.0.
* Fri Jun 16 2023 Python Maint <python-maint@redhat.com> - 8.0.0-2
- Rebuilt for Python 3.12
* Tue May 30 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0-1
- Update to 8.0.0.
* Tue May 23 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0~rc1-1
- Update to 8.0.0~rc1.
* Tue May 16 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0~b1-1
- Update to 8.0.0~b1.
* Wed May 03 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0~a3-1
- Update to 8.0.0~a3.
* Thu Apr 27 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0~a2-1
- Update to 8.0.0~a2.
* Thu Apr 20 2023 Maxwell G <maxwell@gtmx.me> - 8.0.0~a1-1
- Update to 8.0.0~a1.
* Wed Mar 29 2023 Maxwell G <maxwell@gtmx.me> - 7.4.0-1
- Update to 7.4.0.
* Wed Mar 01 2023 Maxwell G <maxwell@gtmx.me> - 7.3.0-1
- Update to 7.3.0.
* Tue Jan 31 2023 David Moreau-Simard <moi@dmsimard.com> - 7.2.0-1
- Update to 7.2.0.
* Wed Jan 18 2023 Fedora Release Engineering <releng@fedoraproject.org> - 7.1.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Fri Dec 09 2022 Maxwell G <gotmax@e.email> - 7.1.0-1
- Update to 7.1.0.
* Wed Nov 23 2022 Maxwell G <gotmax@e.email> - 7.0.0-1
- Update to 7.0.0.
* Fri Nov 18 2022 Maxwell G <gotmax@e.email> - 7.0.0~rc1-1
- Update to 7.0.0~rc1.
* Tue Nov 08 2022 Maxwell G <gotmax@e.email> - 7.0.0~b1-1
- Update to 7.0.0~b1.
* Fri Oct 28 2022 Maxwell G <gotmax@e.email> - 7.0.0~a2-1
- Update to 7.0.0~a2.
* Thu Oct 13 2022 Maxwell G <gotmax@e.email> - 6.5.0-1
- Update to 6.5.0.
* Thu Sep 15 2022 Maxwell G <gotmax@e.email> - 6.4.0-1
- Update to 6.4.0.
* Tue Aug 23 2022 Maxwell G <gotmax@e.email> - 6.3.0-1
- Update to 6.3.0.
* Tue Aug 02 2022 Maxwell G <gotmax@e.email> - 6.2.0-1
- Update to 6.2.0.
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.1.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Fri Jul 15 2022 Maxwell G <gotmax@e.email> - 6.1.0-2
- Fix FTI (rhbz#2107532).
* Thu Jul 14 2022 Maxwell G <gotmax@e.email> - 6.1.0-1
- Update to 6.1.0.
* Wed Jun 22 2022 Maxwell G <gotmax@e.email> - 6.0.0-1
- Update to 6.0.0.
* Wed Jun 22 2022 Maxwell G <gotmax@e.email> - 6.0.0~rc1-1
- Update to 6.0.0~rc1.
- Stop duplicating docs and licenses.
- Don't remove tests in %%prep that are now handled by setup.py.
- Hardlink duplicated files and fix rpmlint errors
* Thu Jun 16 2022 Python Maint <python-maint@redhat.com> - 5.9.0-2
- Rebuilt for Python 3.11
* Wed Jun 08 2022 Maxwell G <gotmax@e.email> - 5.9.0-1
- Update to 5.9.0.
* Thu May 19 2022 Maxwell G <gotmax@e.email> - 5.8.0-1
- Update to 5.8.0.
- Remove fortinet.fortios patch.
* Wed Apr 27 2022 Maxwell G <gotmax@e.email> - 5.7.0-1
- Update to 5.7.0.
- Fix SyntaxError in fortinet.fortios collection.
- Fix rpmlint errors
* Mon Apr 25 2022 Maxwell G <gotmax@e.email> - 5.6.0-2
- Ensure correct version of ansible-core is available at buildtime.
- Implement support for epel8.
* Wed Apr 06 2022 Kevin Fenzi <kevin@scrye.com> - 5.6.0-1
- Update to 5.6.0.
* Tue Mar 15 2022 David Moreau-Simard <moi@dmsimard.com> - 5.5.0-1
- Update to latest upstream release
* Tue Feb 22 2022 David Moreau-Simard <moi@dmsimard.com> - 5.4.0-1
- Update to latest upstream release
* Wed Feb 16 2022 Maxwell G <gotmax@e.email> - 5.3.0-2
- Fix shebangs.
* Tue Feb 1 2022 David Moreau-Simard <moi@dmsimard.com> - 5.3.0-1
- Update to latest upstream release
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 5.2.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Wed Jan 12 2022 David Moreau-Simard <moi@dmsimard.com> - 5.2.0-1
- Update to latest upstream release
* Tue Jan 11 2022 David Moreau-Simard <moi@dmsimard.com> - 5.1.0-1
- Update to latest upstream release
- Refactor to take into account split from ansible-core after ansible 2.9, see: https://fedoraproject.org/wiki/Changes/Ansible5
- Remove patches intended for Ansible 2.9
- Removed packaging macros (soon included in ansible-packaging, see rhbz#2038591)
- Removed provides/obsoletes on ansible-python3
* Mon Nov 01 2021 Kevin Fenzi <kevin@scrye.com> - 2.9.27-2
- Add patch for oracle linux Fixes rhbz#2018369
* Mon Oct 11 2021 Kevin Fenzi <kevin@scrye.com> - 2.9.27-1
- Update to 2.9.27. Fixes rhbz#2012918
@ -487,7 +357,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
- Update to 2.9.11.
* Thu Jun 18 2020 Kevin Fenzi <kevin@scrye.com> - 2.9.10-1
- Update to 2.9.10.
- Update to 2.9.10.
* Fri May 29 2020 Charalampos Stratakis <cstratak@redhat.com> - 2.9.9-3
- Fix Python 3.9 compatibility (#1808674)
@ -577,7 +447,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
- Fixes for various releases build/test issues.
* Fri May 17 2019 Kevin Fenzi <kevin@scrye.com> - 2.8.0-1
- Update to 2.8.0 final.
- Update to 2.8.0 final.
- Add datadirs for other packages to land ansible files in.
* Fri May 10 2019 Kevin Fenzi <kevin@scrye.com> - 2.8.0-0.4rc3
@ -723,7 +593,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
- Conditionalize jmespath to work around amazon linux issues. Fixes bug #1494640
* Tue Sep 19 2017 Kevin Fenzi <kevin@scrye.com> - 2.4.0.0-1
- Update to 2.4.0.
- Update to 2.4.0.
* Tue Aug 08 2017 Kevin Fenzi <kevin@scrye.com> - 2.3.2.0-1
- Update to 2.3.2. Fixes bugs #1471017 #1461116 #1465586
@ -876,7 +746,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
- Update to 1.9.1
* Wed Mar 25 2015 Kevin Fenzi <kevin@scrye.com> 1.9.0.1-2
- Drop upstreamed epel6 patches.
- Drop upstreamed epel6 patches.
* Wed Mar 25 2015 Kevin Fenzi <kevin@scrye.com> 1.9.0.1-1
- Update to 1.9.0.1
@ -927,7 +797,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
- Update to 1.6.9 with more shell quoting fixes.
* Tue Jul 22 2014 Kevin Fenzi <kevin@scrye.com> 1.6.8-1
- Update to 1.6.8 with fixes for shell quoting from previous release.
- Update to 1.6.8 with fixes for shell quoting from previous release.
- Fixes bugs #1122060 #1122061 #1122062
* Mon Jul 21 2014 Kevin Fenzi <kevin@scrye.com> 1.6.7-1
@ -1023,7 +893,7 @@ mv docs %{buildroot}%{_pkgdocdir}/ansible_collections
* Thu Sep 12 2013 Kevin Fenzi <kevin@scrye.com> 1.3.0-1
- Update to 1.3.0
- Drop node-fireball subpackage entirely.
- Obsolete/provide fireball subpackage.
- Obsolete/provide fireball subpackage.
- Add Requires python-keyczar on main package for accelerated mode.
* Wed Aug 21 2013 Kevin Fenzi <kevin@scrye.com> 1.2.3-2

View file

@ -0,0 +1,43 @@
diff --color -Nur ansible-2.9.16.orig/test/lib/ansible_test/_data/completion/docker.txt ansible-2.9.16/test/lib/ansible_test/_data/completion/docker.txt
--- ansible-2.9.16.orig/test/lib/ansible_test/_data/completion/docker.txt 2020-12-14 15:48:25.000000000 -0800
+++ ansible-2.9.16/test/lib/ansible_test/_data/completion/docker.txt 2020-12-17 11:38:44.409269125 -0800
@@ -1,4 +1,4 @@
-default name=quay.io/ansible/default-test-container:1.10.1 python=3.6,2.6,2.7,3.5,3.7,3.8 seccomp=unconfined
+default name=quay.io/ansible/default-test-container:1.10.1 python=3.6,2.6,2.7,3.5,3.7,3.8,3.9,3.10 seccomp=unconfined
centos6 name=quay.io/ansible/centos6-test-container:1.26.0 python=2.6 seccomp=unconfined
centos7 name=quay.io/ansible/centos7-test-container:1.8.0 python=2.7 seccomp=unconfined
centos8 name=quay.io/ansible/centos8-test-container:1.10.0 python=3.6 seccomp=unconfined
diff --color -Nur ansible-2.9.16.orig/test/lib/ansible_test/_data/sanity/compile/compile.py ansible-2.9.16/test/lib/ansible_test/_data/sanity/compile/compile.py
--- ansible-2.9.16.orig/test/lib/ansible_test/_data/sanity/compile/compile.py 2020-12-14 15:48:25.000000000 -0800
+++ ansible-2.9.16/test/lib/ansible_test/_data/sanity/compile/compile.py 2020-12-17 11:36:47.712080958 -0800
@@ -3,9 +3,16 @@
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
-import parser
-import sys
+import warnings
+
+with warnings.catch_warnings():
+ # The parser module is deprecated as of Python 3.9.
+ # This implementation will need to be updated to use another solution.
+ # Until then, disable the deprecation warnings to prevent test failures.
+ warnings.simplefilter('ignore', DeprecationWarning)
+ import parser
+import sys
def main():
status = 0
diff --color -Nur ansible-2.9.16.orig/test/lib/ansible_test/_internal/util.py ansible-2.9.16/test/lib/ansible_test/_internal/util.py
--- ansible-2.9.16.orig/test/lib/ansible_test/_internal/util.py 2020-12-14 15:48:25.000000000 -0800
+++ ansible-2.9.16/test/lib/ansible_test/_internal/util.py 2020-12-17 11:36:47.713080960 -0800
@@ -110,6 +110,8 @@
'3.6',
'3.7',
'3.8',
+ '3.9',
+ '3.10',
)

View file

@ -1,13 +0,0 @@
# Copyright (C) 2023 Maxwell G <maxwell@gtmx.me>
# SPDX-License-Identifier: MIT
--- !Policy
product_versions:
- fedora-*
decision_contexts:
- bodhi_update_push_testing
- bodhi_update_push_stable
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
...

7
macros.ansible Normal file
View file

@ -0,0 +1,7 @@
%ansible_collection_url() https://galaxy.ansible.com/%{collection_namespace}/%{collection_name}
%ansible_collection_build() ansible-galaxy collection build
%ansible_collection_install() ansible-galaxy collection install -n -p %{buildroot}%{_datadir}/ansible/collections %{collection_namespace}-%{collection_name}-%{version}.tar.gz
%ansible_collection_files %{_datadir}/ansible/collections/ansible_collections/%{collection_namespace}/

View file

@ -1 +1 @@
SHA512 (ansible-13.1.0.tar.gz) = 2e7abd85b44d48ea756c65906811c9fa5519ce5d9ecaca71c718446a52dfc3dff97597d048f071ca820ea606ee2de670e8a0746717f95e2ce636db06273b3544
SHA512 (ansible-2.9.27.tar.gz) = 99987b8a1d243ef3496d66178774c33b05951daaff584b12e645c0176391805f90d00780e86adec01316b28645287489326218c0de7c10084552da90848735c7

View file

@ -1,17 +0,0 @@
# Copyright (C) 2023 Maxwell G <maxwell@gtmx.me>
# SPDX-License-Identifier: MIT
summary: Run ansible-core smoke tests with ansible bundle installed
discover:
- name: Smoke tests with ansible
how: shell
tests:
- name: Run tests/smoke.sh
test: tests/smoke.sh
require:
- python3-dnf
- dnf-plugins-core
- ansible-core
- ansible
execute:
how: tmt

View file

@ -1,7 +0,0 @@
#!/usr/bin/bash -x
# Copyright (C) 2023 Maxwell G <maxwell@gtmx.me>
# SPDX-License-Identifier: MIT
set -euo pipefail
curl -L https://src.fedoraproject.org/rpms/ansible-core/raw/rawhide/f/tests/smoke.sh | bash -x