## START: Set by rpmautospec ## (rpmautospec version 0.7.3) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %global pkgname aws-cli Name: awscli2 Version: 2.22.22 Release: %autorelease Summary: Universal Command Line Environment for AWS, version 2 # all files are licensed under Apache-2.0, except: # - awscli/topictags.py is MIT # - awscli/botocore/vendored/six.py is MIT License: Apache-2.0 AND MIT URL: https://github.com/aws/aws-cli/tree/v2 Source0: https://github.com/aws/aws-cli/archive/%{version}/%{pkgname}-%{version}.tar.gz # adapt to whitespace formatting changes and removal of OrderedDict in ruamel-yaml Patch0: ruamel-yaml-0.17.32.patch # fix Python 3.12 incompatibilities Patch1: python312.patch # fix incorrect assertions in TestKubeconfigLoader Patch2: assertions.patch # Bump ceiling for botocore memory leak tests # https://github.com/aws/aws-cli/pull/8744 # https://github.com/boto/botocore/issues/3205 Patch3: 0001-Bump-the-ceiling-for-botocore-memory-leak-tests-to-1.patch # compatibility fixes for urllib3 v2 Patch4: urllib3-v2.patch BuildArch: noarch BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python-unversioned-command BuildRequires: procps-ng Recommends: groff Provides: bundled(python3dist(botocore)) = 2.0.0 Provides: bundled(python3dist(s3transfer)) = 0.5.1 Provides: awscli = %{version}-%{release} Obsoletes: awscli < 2 # provide an upgrade path from awscli-2 (Amazon Linux) Provides: awscli-2 = %{version}-%{release} Obsoletes: awscli-2 < %{version}-%{release} # python-awscrt does not build on s390x ExcludeArch: s390x %description This package provides version 2 of the unified command line interface to Amazon Web Services. %prep %autosetup -p1 -n %{pkgname}-%{version} # fix permissions find awscli/examples/ -type f -name '*.rst' -executable -exec chmod -x '{}' + # remove version caps on dependencies sed -i 's/,<=\?[^"]*"/"/' pyproject.toml # use unittest.mock find -type f -name '*.py' -exec sed \ -e 's/^\( *\)import mock$/\1from unittest import mock/' \ -e 's/^\( *\)from mock import mock/\1from unittest import mock/' \ -e 's/^\( *\)from mock import/\1from unittest.mock import/' \ -i '{}' + # Fedora does not run coverage tests. # mock is deprecated in Fedora. We use unittest.mock. # pip-tools is not used directly by the unit tests. # pytest-xdist is unwanted in RHEL. sed \ -e 's|==.*||' \ -e '/coverage/d' \ -e '/mock/d' \ -e '/pip-tools/d' \ -e '/pytest-cov/d' \ %{?rhel:-e '/pytest-xdist/d'} \ requirements-test.txt > _requirements-test.txt %generate_buildrequires %pyproject_buildrequires _requirements-test.txt %build %pyproject_wheel %install %pyproject_install %pyproject_save_files awscli # remove unnecessary scripts rm -vf %{buildroot}%{_bindir}/{aws_bash_completer,aws_zsh_completer.sh,aws.cmd} # install shell completion install -Dpm0644 bin/aws_bash_completer \ %{buildroot}%{bash_completions_dir}/aws install -Dpm0644 bin/aws_zsh_completer.sh \ %{buildroot}%{zsh_completions_dir}/_awscli %check # it appears that some tests modify the environment and remove PYTHONPATH # so it's not passed to botocore cmd-runner, inject it here sed -i '/self.driver.start(env=env)/i \ \ \ \ \ \ \ \ env["PYTHONPATH"] = "%{buildroot}%{python3_sitelib}"' \ tests/utils/botocore/__init__.py export TESTS_REMOVE_REPO_ROOT_FROM_PATH=1 TZ=UTC export OPENSSL_ENABLE_SHA1_SIGNATURES=yes %pytest --verbose %{!?rhel:--numprocesses=auto --dist=loadfile --maxprocesses=4} tests/unit tests/functional %files -f %{pyproject_files} %license LICENSE.txt %doc README.rst %{_bindir}/aws %{_bindir}/aws_completer %{bash_completions_dir}/aws %{zsh_completions_dir}/_awscli %changelog ## START: Generated by rpmautospec * Fri Dec 20 2024 Packit - 2.22.22-1 - Update to 2.22.22 upstream release - Resolves: rhbz#2330452 * Wed Dec 04 2024 Packit - 2.22.10-1 - Update to 2.22.10 upstream release - Resolves: rhbz#2321230 * Sat Oct 19 2024 Packit - 2.18.10-1 - Update to 2.18.10 upstream release - Resolves: rhbz#2316737 * Thu Oct 03 2024 Packit - 2.17.61-1 - Update to 2.17.61 upstream release - Resolves: rhbz#2312409 * Fri Sep 13 2024 Packit - 2.17.50-1 - Update to 2.17.50 upstream release - Resolves: rhbz#2307522 * Fri Aug 23 2024 Nikola Forró - 2.17.35-2 - Backport botocore compatibility fixes for urllib3 v2 * Thu Aug 22 2024 Packit - 2.17.35-1 - Update to 2.17.35 upstream release - Resolves: rhbz#2301776 * Sat Jul 27 2024 Packit - 2.17.18-1 - Update to 2.17.18 upstream release - Resolves: rhbz#2298934 * Fri Jul 26 2024 Yaakov Selkowitz - 2.17.13-3 - Avoid SHA-1 test failures * Wed Jul 17 2024 Fedora Release Engineering - 2.17.13-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Tue Jul 16 2024 Packit - 2.17.13-1 - Update to 2.17.13 upstream release - Resolves: rhbz#2295429 * Tue Jul 02 2024 Packit - 2.17.6-1 - Update to 2.17.6 upstream release - Resolves: rhbz#2295153 * Wed Jun 26 2024 Packit - 2.17.2-1 - Update to 2.17.2 upstream release - Resolves: rhbz#2294375 * Tue Jun 25 2024 Packit - 2.17.1-1 - Update to 2.17.1 upstream release - Resolves: rhbz#2294170 * Fri Jun 21 2024 Packit - 2.17.0-1 - Update to 2.17.0 upstream release - Resolves: rhbz#2271182 * Fri Jun 14 2024 Packit - 2.16.8-1 - Update to 2.16.8 upstream release * Thu Jun 13 2024 Adam Williamson - 2.15.31-3 - Backport PR #8744 to fix tests with Python 3.13 * Sat Jun 08 2024 Python Maint - 2.15.31-2 - Rebuilt for Python 3.13 * Fri Mar 22 2024 Packit - 2.15.31-1 - [packit] 2.15.31 upstream release - Resolves rhbz#2270622 * Sat Mar 16 2024 Packit - 2.15.30-1 - [packit] 2.15.30 upstream release - Resolves rhbz#2259063 * Tue Jan 23 2024 Fedora Release Engineering - 2.15.10-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Fri Jan 19 2024 Fedora Release Engineering - 2.15.10-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Wed Jan 17 2024 Packit - 2.15.10-1 - [packit] 2.15.10 upstream release - Resolves rhbz#2255621 * Sat Dec 16 2023 Packit - 2.15.2-1 - [packit] 2.15.2 upstream release - Resolves rhbz#2254838 * Fri Dec 15 2023 Packit - 2.15.1-1 - [packit] 2.15.1 upstream release - Resolves rhbz#2251124 * Thu Dec 07 2023 Nikola Forró - 2.13.37-2 - Fix Python 3.12 patch * Sat Nov 18 2023 Packit - 2.13.37-1 - [packit] 2.13.37 upstream release - Resolves rhbz#2250398 * Wed Nov 15 2023 Packit - 2.13.36-1 - [packit] 2.13.36 upstream release - Resolves rhbz#2247595 * Fri Oct 27 2023 Packit - 2.13.30-1 - [packit] 2.13.30 upstream release - Resolves rhbz#2203325 Upstream tag: 2.13.30 Upstream commit: 580ceb06 * Tue Oct 24 2023 Packit - 2.13.28-1 - [packit] 2.13.28 upstream release * Tue Oct 24 2023 Nikola Forró - 2.13.26-4 - Fix ruamel-yaml patch and improve Python version compatibility * Wed Oct 18 2023 Yaakov Selkowitz - 2.13.26-3 - Skip flaky yaml output test * Mon Oct 16 2023 Miro Hrončok - 2.13.26-2 - Don't use pytest-xdist in ELN * Sat Oct 14 2023 Packit - 2.13.26-1 - [packit] 2.13.26 upstream release * Wed Oct 04 2023 Packit - 2.13.23-1 - [packit] 2.13.23 upstream release * Sat Sep 09 2023 Packit - 2.13.17-1 - [packit] 2.13.17 upstream release * Thu Aug 24 2023 Packit - 2.13.12-1 - [packit] 2.13.12 upstream release * Tue Aug 22 2023 Packit - 2.13.11-1 - [packit] 2.13.11 upstream release * Thu Aug 17 2023 Nikola Forró - 2.13.9-3 - Fix Packit config * Mon Aug 14 2023 Nikola Forró - 2.13.9-2 - Make pull-from-upstream react only to v2 tags * Fri Aug 11 2023 Packit - 2.13.9-1 - [packit] 2.13.9 upstream release * Sat Aug 05 2023 Packit - 2.13.7-1 - [packit] 2.13.7 upstream release * Fri Aug 04 2023 Packit - 2.13.6-1 - [packit] 2.13.6 upstream release * Fri Jul 28 2023 Davide Cavalca - 2.13.4-2 - Fix build on ELN * Thu Jul 27 2023 Packit - 2.13.4-1 - [packit] 2.13.4 upstream release * Wed Jul 26 2023 Nikola Forró - 2.13.3-1 - Update to 2.13.3 and fix FTBFS * Wed Jul 19 2023 Fedora Release Engineering - 2.12.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Thu Jun 15 2023 Python Maint - 2.12.0-2 - Rebuilt for Python 3.12 * Thu Jun 15 2023 Packit - 2.12.0-1 - [packit] 2.12.0 upstream release * Fri Jun 09 2023 Packit - 2.11.27-1 - [packit] 2.11.27 upstream release * Thu Jun 08 2023 Packit - 2.11.26-1 - [packit] 2.11.26 upstream release * Mon Jun 05 2023 Packit - 2.11.25-1 - [packit] 2.11.25 upstream release * Thu Jun 01 2023 Packit - 2.11.24-1 - [packit] 2.11.24 upstream release * Sat May 27 2023 Packit - 2.11.23-1 - [packit] 2.11.23 upstream release * Fri May 26 2023 Packit - 2.11.22-1 - [packit] 2.11.22 upstream release * Sat May 20 2023 Packit - 2.11.21-1 - [packit] 2.11.21 upstream release * Sat May 13 2023 Packit - 2.11.20-1 - [packit] 2.11.20 upstream release * Thu May 11 2023 Packit - 2.11.19-1 - [packit] 2.11.19 upstream release * Wed May 10 2023 Nikola Forró - 2.11.18-1 - Update to 2.11.18 and add missing Provides * Mon May 08 2023 Maxwell G - 2.11.17-4 - fix typo in comment * Fri May 05 2023 Nikola Forró - 2.11.17-1 - Initial package ## END: Generated by rpmautospec