diff --git a/custodia.spec b/custodia.spec index 56eb6ec..a75c037 100644 --- a/custodia.spec +++ b/custodia.spec @@ -4,7 +4,7 @@ Name: custodia Version: 0.3.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A service to manage, retrieve and store secrets for other processes License: GPLv3+ @@ -43,7 +43,11 @@ BuildRequires: python3-docutils BuildRequires: python3-systemd %endif +%if 0%{?with_python3} +Requires: python3-custodia = %{version}-%{release} +%else Requires: python2-custodia = %{version}-%{release} +%endif %global overview \ Custodia is a Secrets Service Provider, it stores or proxies access to \ @@ -64,7 +68,7 @@ A service to manage, retrieve and store secrets for other processes %package -n python2-custodia Summary: Sub-package with python2 custodia modules -Provides: python-custodia = %{version} +Provides: python-custodia = %{version}-%{release} Obsoletes: python-custodia <= 0.1.0 Requires: python2-configparser Requires: python-jwcrypto @@ -134,9 +138,9 @@ export PIP_INDEX_URL=http://host.invalid./ # Don't try to download dnspython3. The package is provided by python3-dns export PIP_NO_DEPS=yes -#tox --sitepackages -e py27 -- --skip-servertests +tox --sitepackages -e py27 -- --skip-servertests %if 0%{?with_python3} -#tox --sitepackages -e py35 -- --skip-servertests +tox --sitepackages -e py35 -- --skip-servertests %endif @@ -153,7 +157,6 @@ mkdir -p %{buildroot}/%{_localstatedir}/log/custodia %{__python2} setup.py install --skip-build --root %{buildroot} mv %{buildroot}/%{_bindir}/custodia %{buildroot}/%{_sbindir}/custodia -mv %{buildroot}/%{_bindir}/custodia-cli %{buildroot}/%{_bindir}/custodia-cli-2 install -m 644 -t "%{buildroot}/%{_mandir}/man7" man/custodia.7 install -m 644 -t "%{buildroot}/%{_defaultdocdir}/custodia" README API.md install -m 644 -t "%{buildroot}/%{_defaultdocdir}/custodia/examples" custodia.conf @@ -163,9 +166,9 @@ install -m 644 %{SOURCE4} %{buildroot}%{_unitdir} install -m 644 %{SOURCE5} %{buildroot}%{_tmpfilesdir}/custodia.conf %if 0%{?with_python3} +# overrides /usr/bin/custodia-cli and /usr/sbin/custodia with Python 3 shebang %{__python3} setup.py install --skip-build --root %{buildroot} -rm %{buildroot}/%{_bindir}/custodia -mv %{buildroot}/%{_bindir}/custodia-cli-2 %{buildroot}/%{_bindir}/custodia-cli +mv %{buildroot}/%{_bindir}/custodia %{buildroot}/%{_sbindir}/custodia %endif @@ -208,6 +211,10 @@ mv %{buildroot}/%{_bindir}/custodia-cli-2 %{buildroot}/%{_bindir}/custodia-cli %changelog +* Thu Mar 02 2017 Christian Heimes - 0.3.0-2 +- Run Custodia daemon with Python 3 +- Resolves: Bug 1426737 - custodia: Provide a Python 3 subpackage + * Wed Mar 01 2017 Christian Heimes - 0.3.0-1 - Update to custodia 0.3.0 - Run tests with global site packages