import ansible-pcp-2.2.2-2.el9
This commit is contained in:
parent
8e464d127b
commit
786525d751
@ -1,26 +1,55 @@
|
|||||||
%if 0%{?rhel}
|
|
||||||
%global collection_namespace redhat
|
|
||||||
%global collection_name rhel_metrics
|
|
||||||
%bcond_with ansible
|
|
||||||
%else
|
|
||||||
%global collection_namespace performancecopilot
|
|
||||||
%global collection_name metrics
|
|
||||||
%bcond_without ansible
|
|
||||||
%endif
|
|
||||||
|
|
||||||
Name: ansible-pcp
|
Name: ansible-pcp
|
||||||
Version: 2.2.2
|
Version: 2.2.2
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: Ansible Metric collection for Performance Co-Pilot
|
Summary: Ansible Metric collection for Performance Co-Pilot
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: https://github.com/performancecopilot/ansible-pcp
|
URL: https://github.com/performancecopilot/ansible-pcp
|
||||||
Source: https://github.com/performancecopilot/ansible-pcp/archive/v%{version}/%{name}-%{version}.tar.gz
|
Source: https://github.com/performancecopilot/ansible-pcp/archive/v%{version}/%{name}-%{version}.tar.gz
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
%if %{with ansible}
|
%if 0%{?rhel}
|
||||||
BuildRequires: ansible >= 2.9.10
|
%global collection_namespace redhat
|
||||||
|
%global collection_name rhel_metrics
|
||||||
|
%else
|
||||||
|
%global collection_namespace performancecopilot
|
||||||
|
%global collection_name metrics
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if 0%{?rhel} >= 8
|
||||||
|
Requires: (ansible-core >= 2.11.0 or ansible >= 2.9.0)
|
||||||
|
%endif
|
||||||
|
|
||||||
|
# NOTE: Even though ansible-core is in 8.6, it is only available
|
||||||
|
# at *runtime*, not at *buildtime* - so we can't have
|
||||||
|
# ansible-core as a build_dep on RHEL8
|
||||||
|
%if 0%{?fedora} || 0%{?rhel} >= 9
|
||||||
|
%global have_ansible 0
|
||||||
|
%global ansible_build_dep ansible-core >= 2.11.0
|
||||||
|
%else
|
||||||
|
%if 0%{?rhel} && ! 0%{?epel}
|
||||||
|
%global have_ansible 1
|
||||||
|
%else
|
||||||
|
%global have_ansible 0
|
||||||
|
%global ansible_build_dep ansible >= 2.9.10
|
||||||
|
%endif
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if %{have_ansible}
|
||||||
|
BuildRequires: %{ansible_build_dep}
|
||||||
|
# package has been removed from RHEL9
|
||||||
|
%if 0%{?rhel} >= 9
|
||||||
|
%global have_ansible_lint 0
|
||||||
|
%else
|
||||||
|
%global have_ansible_lint 1
|
||||||
|
%endif
|
||||||
|
%else
|
||||||
|
%global have_ansible_lint 0
|
||||||
|
%global ansible_collection_files %{_datadir}/ansible/collections/ansible_collections/%{collection_namespace}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if %{have_ansible_lint}
|
||||||
BuildRequires: python3-ansible-lint
|
BuildRequires: python3-ansible-lint
|
||||||
%endif
|
%endif
|
||||||
BuildArch: noarch
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
A collection containing roles for Performance Co-Pilot (PCP) and related
|
A collection containing roles for Performance Co-Pilot (PCP) and related
|
||||||
@ -75,24 +104,26 @@ find . -name \*.yml -o -name \*.md | while read file; do
|
|||||||
$file
|
$file
|
||||||
done
|
done
|
||||||
|
|
||||||
%if %{without ansible}
|
%build
|
||||||
%define ansible_collection_files %{_datadir}/ansible/collections/ansible_collections/%{collection_namespace}
|
%if %{have_ansible}
|
||||||
# Empty command. We don't have ansible-galaxy.
|
%ansible_collection_build
|
||||||
%define ansible_collection_build() tar -cf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz .
|
%else
|
||||||
# Simply copy everything instead of galaxy-installing the built artifact.
|
tar -cf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz .
|
||||||
%define ansible_collection_install() mkdir -p %{buildroot}%{ansible_collection_files}/%{collection_name}; (cd %{buildroot}%{ansible_collection_files}/%{collection_name}; tar -xf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz)
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%build
|
|
||||||
%ansible_collection_build
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
%if %{have_ansible}
|
||||||
%ansible_collection_install
|
%ansible_collection_install
|
||||||
|
%else
|
||||||
|
mkdir -p %{buildroot}%{ansible_collection_files}/%{collection_name}
|
||||||
|
cd %{buildroot}%{ansible_collection_files}/%{collection_name}
|
||||||
|
tar -xf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz
|
||||||
|
%endif
|
||||||
|
|
||||||
%check
|
%check
|
||||||
mv yamllint.yml .yamllint.yml
|
mv yamllint.yml .yamllint.yml
|
||||||
mv yamllint_defaults.yml .yamllint_defaults.yml
|
mv yamllint_defaults.yml .yamllint_defaults.yml
|
||||||
%if %{with ansible}
|
%if %{have_ansible_lint}
|
||||||
ansible-lint `find roles -name \*.yml`
|
ansible-lint `find roles -name \*.yml`
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
@ -102,22 +133,27 @@ ansible-lint `find roles -name \*.yml`
|
|||||||
%{ansible_collection_files}
|
%{ansible_collection_files}
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Feb 15 2022 Nathan Scott <nathans@redhat.com> 2.2.2-2
|
||||||
|
- RHEL8.6+, RHEL9+, Fedora - add "ansible-core or ansible" dep
|
||||||
|
|
||||||
* Fri Nov 12 2021 Nathan Scott <nathans@redhat.com> 2.2.2-1
|
* Fri Nov 12 2021 Nathan Scott <nathans@redhat.com> 2.2.2-1
|
||||||
- Resolves Grafana provisioning issue (BZ 1967321)
|
- Resolves Grafana provisioning issue (BZ 1967321)
|
||||||
- Latest upstream release (BZ 2022170)
|
- Latest upstream release (BZ 2022168)
|
||||||
|
|
||||||
* Mon Aug 30 2021 Nathan Scott <nathans@redhat.com> 2.2.1-1
|
* Thu Aug 26 2021 Nathan Scott <nathans@redhat.com> 2.2.1-1
|
||||||
- Latest upstream release
|
- Latest upstream release
|
||||||
|
|
||||||
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 2.1.4-2
|
|
||||||
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
||||||
Related: rhbz#1991688
|
|
||||||
|
|
||||||
* Fri Jun 25 2021 Nathan Scott <nathans@redhat.com> 2.1.4-1
|
* Fri Jun 25 2021 Nathan Scott <nathans@redhat.com> 2.1.4-1
|
||||||
- Latest upstream release
|
- Latest upstream release
|
||||||
|
|
||||||
* Wed Jun 09 2021 Nathan Scott <nathans@redhat.com> 2.1.3-1
|
* Tue Jun 08 2021 Nathan Scott <nathans@redhat.com> 2.1.3-3
|
||||||
- Initial version of RHEL-9 package (BZ 1957566)
|
- Rebuild for full pass through CI/gating processes
|
||||||
|
|
||||||
|
* Mon Jun 07 2021 Nathan Scott <nathans@redhat.com> 2.1.3-2
|
||||||
|
- Drop unnecessary package dependency on Ansible
|
||||||
|
|
||||||
|
* Thu Jun 03 2021 Nathan Scott <nathans@redhat.com> 2.1.3-1
|
||||||
|
- Initial version of RHEL package (BZ 1854055)
|
||||||
- Latest upstream release
|
- Latest upstream release
|
||||||
|
|
||||||
* Fri Feb 05 2021 Nathan Scott <nathans@redhat.com> 2.1.2-1
|
* Fri Feb 05 2021 Nathan Scott <nathans@redhat.com> 2.1.2-1
|
||||||
|
Loading…
Reference in New Issue
Block a user