| |
@@ -1,117 +1,83 @@
|
| |
- %global package_name ara
|
| |
+ %global srcname ara
|
| |
|
| |
- %global common_desc \
|
| |
- ARA Records Ansible playbook runs and makes the recorded data available and \
|
| |
- intuitive for users and systems.
|
| |
-
|
| |
- Name: %{package_name}
|
| |
- Version: 0.16.1
|
| |
- Release: 4%{?dist}
|
| |
- Summary: ARA Records Ansible playbook runs
|
| |
+ Name: %{srcname}
|
| |
+ Version: 1.1.0
|
| |
+ Release: 1%{?dist}
|
| |
+ Summary: ARA Records Ansible playbooks and makes them easier to understand and troubleshoot.
|
| |
|
| |
License: GPLv3
|
| |
- URL: https://git.openstack.org/cgit/openstack/ara
|
| |
- Source0: https://pypi.io/packages/source/a/%{package_name}/%{package_name}-%{version}.tar.gz
|
| |
- Source1: ara-server.service
|
| |
- Source2: ara.cfg
|
| |
- Source3: logging-config.yaml
|
| |
- Source4: ara.logrotate
|
| |
+ URL: https://github.com/ansible-community/ara
|
| |
+ Source0: https://pypi.io/packages/source/a/%{srcname}/%{srcname}-%{version}.tar.gz
|
| |
BuildArch: noarch
|
| |
|
| |
- %{?systemd_requires}
|
| |
- BuildRequires: systemd
|
| |
BuildRequires: git
|
| |
|
| |
- Requires: python3-%{package_name} = %{version}-%{release}
|
| |
- Requires: %{package_name}-common = %{version}-%{release}
|
| |
+ Requires: python3-%{srcname} = %{version}-%{release}
|
| |
+ Requires: %{srcname}-common = %{version}-%{release}
|
| |
|
| |
%description
|
| |
- %{common_desc}
|
| |
+ %{summary}
|
| |
+
|
| |
+ It provides Ansible plugins to record Ansible playbooks to a local or remote
|
| |
+ database and an API to query and browse playbook results.
|
| |
|
| |
- %package -n python3-%{package_name}
|
| |
+ %package -n python3-%{srcname}
|
| |
Summary: %{summary}
|
| |
|
| |
BuildRequires: python3-devel
|
| |
BuildRequires: python3-pbr
|
| |
- BuildRequires: python3-setuptools
|
| |
- # Test dependencies for check macro
|
| |
- BuildRequires: ansible >= 2.4.0.0
|
| |
- BuildRequires: python3-cliff
|
| |
- BuildRequires: python3-flask >= 0.12.4
|
| |
- BuildRequires: python3-flask-migrate
|
| |
- BuildRequires: python3-flask-script
|
| |
- BuildRequires: python3-frozen-flask
|
| |
- BuildRequires: python3-jinja2 >= 2.9
|
| |
- BuildRequires: python3-junit_xml
|
| |
- BuildRequires: python3-lxml
|
| |
- BuildRequires: python3-mock
|
| |
- BuildRequires: python3-oslo-serialization
|
| |
- BuildRequires: python3-oslo-utils
|
| |
- BuildRequires: python3-pyfakefs
|
| |
- BuildRequires: python3-pygments >= 1.6
|
| |
- BuildRequires: python3-pytest
|
| |
- BuildRequires: python3-six
|
| |
- BuildRequires: python3-sqlalchemy
|
| |
- BuildRequires: python3-subunit
|
| |
- BuildRequires: python3-XStatic
|
| |
- BuildRequires: python3-XStatic-Bootstrap-SCSS
|
| |
- BuildRequires: python3-XStatic-DataTables
|
| |
- BuildRequires: python3-XStatic-jQuery
|
| |
- BuildRequires: python3-XStatic-Patternfly
|
| |
- BuildRequires: python3-XStatic-Patternfly-Bootstrap-Treeview
|
| |
-
|
| |
- Requires: ansible >= 2.4.0.0
|
| |
- Requires: python3-cliff
|
| |
- Requires: python3-flask >= 0.12.4
|
| |
- Requires: python3-flask-migrate
|
| |
- Requires: python3-flask-script
|
| |
- Requires: python3-frozen-flask
|
| |
- Requires: python3-jinja2 >= 2.9
|
| |
- Requires: python3-junit_xml
|
| |
- Requires: python3-oslo-serialization
|
| |
- Requires: python3-oslo-utils
|
| |
- Requires: python3-pyfakefs
|
| |
- Requires: python3-pygments >= 1.6
|
| |
- Requires: python3-six
|
| |
- Requires: python3-sqlalchemy
|
| |
- Requires: python3-subunit
|
| |
- Requires: python3-XStatic
|
| |
- Requires: python3-XStatic-Bootstrap-SCSS
|
| |
- Requires: python3-XStatic-DataTables
|
| |
- Requires: python3-XStatic-jQuery
|
| |
- Requires: python3-XStatic-Patternfly
|
| |
- Requires: python3-XStatic-Patternfly-Bootstrap-Treeview
|
| |
-
|
| |
- %{?python_provide:%python_provide python3-%{package_name}}
|
| |
-
|
| |
- %description -n python3-%{package_name}
|
| |
- %{common_desc}
|
| |
|
| |
- %package -n python3-%{package_name}-tests
|
| |
- Summary: Tests for %{package_name}
|
| |
+ Requires: python3-requests
|
| |
|
| |
- Requires: python3-%{package_name} = %{version}-%{release}
|
| |
- Requires: python3-lxml
|
| |
- Requires: python3-mock
|
| |
- Requires: python3-pytest
|
| |
+ %{?python_provide:%python_provide python3-%{srcname}}
|
| |
|
| |
- %description -n python3-%{package_name}-tests
|
| |
- %{common_desc}
|
| |
+ %description -n python3-%{srcname}
|
| |
+ %{summary}
|
| |
|
| |
- This package contains the test files.
|
| |
+ This package contains the python files and Ansible plugins for ARA.
|
| |
|
| |
- %package common
|
| |
- Summary: Common files for %{package_name}
|
| |
+ %package -n python3-%{srcname}-server
|
| |
+ Summary: %{summary}
|
| |
+
|
| |
+ # Test dependencies for check macro
|
| |
+ BuildRequires: python3-django
|
| |
+ BuildRequires: python3-django-cors-headers
|
| |
+ BuildRequires: python3-django-filter
|
| |
+ BuildRequires: python3-django-rest-framework
|
| |
+ BuildRequires: python3-dynaconf
|
| |
+ BuildRequires: python3-factory-boy
|
| |
+ BuildRequires: python3-faker
|
| |
+ BuildRequires: python3-PyYAML
|
| |
+ BuildRequires: python3-whitenoise
|
| |
+
|
| |
+ Requires: python3-%{srcname}
|
| |
+ Requires: python3-django
|
| |
+ Requires: python3-django-cors-headers
|
| |
+ Requires: python3-django-filter
|
| |
+ Requires: python3-django-rest-framework
|
| |
+ Requires: python3-dynaconf
|
| |
+ Requires: python3-PyYAML
|
| |
+ Requires: python3-whitenoise
|
| |
+
|
| |
+ %description -n python3-%{srcname}-server
|
| |
+ %{summary}
|
| |
+
|
| |
+ This package installs the necessary dependencies to run the ARA API server.
|
| |
+
|
| |
+ %package -n python3-%{srcname}-tests
|
| |
+ Summary: %{summary}
|
| |
|
| |
- Requires(pre): shadow-utils
|
| |
+ Requires: python3-%{srcname}-server = %{version}-%{release}
|
| |
+ Requires: python3-factory-boy
|
| |
+ Requires: python3-faker
|
| |
|
| |
- %description common
|
| |
- %{common_desc}
|
| |
+ %description -n python3-%{srcname}-tests
|
| |
+ %{summary}
|
| |
|
| |
- This package contains the common files.
|
| |
+ This package installs the necessary test dependencies and contains the test files.
|
| |
|
| |
%package doc
|
| |
- Summary: Documentation for %{package_name}
|
| |
+ Summary: %{summary}
|
| |
|
| |
BuildRequires: python3-sphinx
|
| |
BuildRequires: python3-sphinx_rtd_theme
|
| |
@@ -119,91 +85,52 @@
|
| |
%description doc
|
| |
%{common_desc}
|
| |
|
| |
- This package contains the documentation.
|
| |
+ This package installs the documentation files.
|
| |
|
| |
%prep
|
| |
- %autosetup -n %{package_name}-%{version} -S git
|
| |
-
|
| |
- # Let RPM handle the requirements
|
| |
- rm -f {,test-}requirements.txt
|
| |
+ %autosetup -n %{srcname}-%{version} -S git
|
| |
|
| |
%build
|
| |
%py3_build
|
| |
- # Disable warning detection as failures: https://review.openstack.org/#/c/491202/
|
| |
- # sphinx-build -W -b html doc/source doc/build/html
|
| |
sphinx-build -b html doc/source doc/build/html
|
| |
|
| |
%install
|
| |
%py3_install
|
| |
|
| |
- # Setup directories
|
| |
- install -d -m 755 %{buildroot}%{_sysconfdir}/%{package_name}
|
| |
- install -d -m 755 %{buildroot}%{_sharedstatedir}/%{package_name}
|
| |
- install -d -m 755 %{buildroot}%{_localstatedir}/log/%{package_name}
|
| |
-
|
| |
- # Setup systemd unit file
|
| |
- install -p -D -m 644 %{SOURCE1} %{buildroot}%{_unitdir}/%{package_name}-server.service
|
| |
-
|
| |
- # Setup default config
|
| |
- install -p -D -m 640 %{SOURCE2} %{buildroot}%{_sysconfdir}/%{package_name}/%{package_name}.cfg
|
| |
- install -p -D -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/%{package_name}/logging-config.yaml
|
| |
-
|
| |
- # Setup logrotate
|
| |
- install -p -D -m 644 %{SOURCE4} %{buildroot}%{_sysconfdir}/logrotate.d/%{package_name}
|
| |
-
|
| |
%check
|
| |
# Run unit tests
|
| |
- %{__python3} -m pytest -v
|
| |
-
|
| |
- %pre common
|
| |
- getent group %{package_name} >/dev/null || groupadd -r %{package_name}
|
| |
- getent passwd %{package_name} >/dev/null || \
|
| |
- useradd -r -g %{package_name} -d %{_sharedstatedir}/%{package_name} \
|
| |
- -s /sbin/nologin -c "User for ARA" %{package_name}
|
| |
- exit 0
|
| |
-
|
| |
- %post
|
| |
- %systemd_post %{package_name}-server.service
|
| |
-
|
| |
- %preun
|
| |
- %systemd_preun %{package_name}-server.service
|
| |
-
|
| |
- %postun
|
| |
- %systemd_postun_with_restart %{package_name}-server.service
|
| |
+ cd %{_builddir}/%{srcname}-%{version}
|
| |
+ %{__python3} manage.py test %{srcname}
|
| |
|
| |
%files
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
- %{_bindir}/ara*
|
| |
- %{_unitdir}/%{package_name}-server.service
|
| |
|
| |
- %files -n python3-%{package_name}
|
| |
+ %files -n python3-%{srcname}
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
- %{python3_sitelib}/%{package_name}
|
| |
- %{python3_sitelib}/%{package_name}-*.egg-info
|
| |
- %exclude %{python3_sitelib}/%{package_name}/tests
|
| |
+ %{python3_sitelib}/%{srcname}
|
| |
+ %{python3_sitelib}/%{srcname}-*.egg-info
|
| |
+ %exclude %{python3_sitelib}/%{srcname}/api/tests
|
| |
|
| |
- %files -n python3-%{package_name}-tests
|
| |
+ %files -n python3-%{srcname}-server
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
- %{python3_sitelib}/%{package_name}/tests
|
| |
+ %{_bindir}/ara-manage
|
| |
|
| |
- %files common
|
| |
+ %files -n python3-%{srcname}-tests
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
- %dir %{_sysconfdir}/%{package_name}
|
| |
- %config(noreplace) %attr(0640, root, %{package_name}) %{_sysconfdir}/%{package_name}/%{package_name}.cfg
|
| |
- %config(noreplace) %attr(0644, root, %{package_name}) %{_sysconfdir}/%{package_name}/logging-config.yaml
|
| |
- %config(noreplace) %{_sysconfdir}/logrotate.d/%{package_name}
|
| |
- %dir %attr(0750, %{package_name}, %{package_name}) %{_localstatedir}/log/%{package_name}
|
| |
- %dir %attr(0750, %{package_name}, %{package_name}) %{_sharedstatedir}/%{package_name}
|
| |
+ %{python3_sitelib}/%{srcname}/api/tests
|
| |
|
| |
%files doc
|
| |
%doc README.rst doc/build/html
|
| |
%license LICENSE
|
| |
|
| |
%changelog
|
| |
+ * Tue Sep 10 2019 David Moreau Simard <dmsimard@redhat.com> - 1.1.0-1
|
| |
+ - Update to latest upstream release
|
| |
+
|
| |
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.16.1-4
|
| |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
| |
|
| |
None