Accepting request 865872 from home:mcalabkova:branches:devel:languages:python

- Ship example conf for each flavor
- Handle binary with update-alternatives

OBS-URL: https://build.opensuse.org/request/show/865872
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-haproxyctl?expand=0&rev=3
This commit is contained in:
Markéta Machová 2021-01-22 09:15:09 +00:00 committed by Git OBS Bridge
parent bd2206c182
commit 8d99a033d9
2 changed files with 18 additions and 5 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Fri Jan 22 09:07:29 UTC 2021 - Markéta Machová <mmachova@suse.com>
- Ship example conf for each flavor
- Handle binary with update-alternatives
-------------------------------------------------------------------
Mon Jul 22 11:17:53 UTC 2019 - Alberto Planas Dominguez <aplanas@suse.com>

View File

@ -52,20 +52,27 @@ cp %{SOURCE1} .
%install
%python_install
%python_clone -a %{buildroot}%{_bindir}/haproxyctl
%python_expand %fdupes %{buildroot}%{$python_sitelib}
mkdir -p %{buildroot}%{_datadir}/%{name}/
cp -a conf %{buildroot}%{_datadir}/%{name}/
%{python_expand mkdir -p %{buildroot}%{_datadir}/$python-haproxyctl/
cp -a conf %{buildroot}%{_datadir}/$python-haproxyctl/}
%check
%{python_expand $python -m unittest discover -s haproxy/tests}
%post
%python_install_alternative haproxyctl
%postun
%python_uninstall_alternative haproxyctl
%files %{python_files}
%doc README.md
%license gpl-3.0.txt
%dir %{_datadir}/%{name}
%dir %{_datadir}/%{python_flavor}-haproxyctl
%{python_sitelib}/*
%{_bindir}/haproxyctl
%{_datadir}/%{name}/*
%python_alternative %{_bindir}/haproxyctl
%{_datadir}/%{python_flavor}-haproxyctl/*
%changelog