!4 Add configure file wsgi-python3.conf
From: @zhaorenhai Reviewed-by: @small_leek Signed-off-by: @small_leek
This commit is contained in:
commit
4a0a77cfb9
@ -6,11 +6,12 @@
|
|||||||
%global sphinxbin %{_bindir}/sphinx-build-3
|
%global sphinxbin %{_bindir}/sphinx-build-3
|
||||||
Name: mod_wsgi
|
Name: mod_wsgi
|
||||||
Version: 4.6.4
|
Version: 4.6.4
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: A WSGI interface for Python web applications in Apache
|
Summary: A WSGI interface for Python web applications in Apache
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: https://modwsgi.readthedocs.io/
|
URL: https://modwsgi.readthedocs.io/
|
||||||
Source0: https://github.com/GrahamDumpleton/mod_wsgi/archive/%{version}.tar.gz#/mod_wsgi-%{version}.tar.gz
|
Source0: https://github.com/GrahamDumpleton/mod_wsgi/archive/%{version}.tar.gz#/mod_wsgi-%{version}.tar.gz
|
||||||
|
Source1: wsgi-python3.conf
|
||||||
Patch1: mod_wsgi-4.5.20-exports.patch
|
Patch1: mod_wsgi-4.5.20-exports.patch
|
||||||
Patch2: Use-official-APIs-for-accessing-interpreter-list.patch
|
Patch2: Use-official-APIs-for-accessing-interpreter-list.patch
|
||||||
Patch3: Changed-functions-to-pre-post-actions-when-forking.patch
|
Patch3: Changed-functions-to-pre-post-actions-when-forking.patch
|
||||||
@ -59,6 +60,8 @@ pushd py3build
|
|||||||
make install DESTDIR=$RPM_BUILD_ROOT LIBEXECDIR=%{_httpd_moddir}
|
make install DESTDIR=$RPM_BUILD_ROOT LIBEXECDIR=%{_httpd_moddir}
|
||||||
mv $RPM_BUILD_ROOT%{_httpd_moddir}/mod_wsgi{,_python3}.so
|
mv $RPM_BUILD_ROOT%{_httpd_moddir}/mod_wsgi{,_python3}.so
|
||||||
install -d -m 755 $RPM_BUILD_ROOT%{_httpd_modconfdir}
|
install -d -m 755 $RPM_BUILD_ROOT%{_httpd_modconfdir}
|
||||||
|
install -p -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_httpd_modconfdir}/10-wsgi-python3.conf
|
||||||
|
|
||||||
%py3_install
|
%py3_install
|
||||||
mv $RPM_BUILD_ROOT%{_bindir}/mod_wsgi-express{,-3}
|
mv $RPM_BUILD_ROOT%{_bindir}/mod_wsgi-express{,-3}
|
||||||
popd
|
popd
|
||||||
@ -66,11 +69,15 @@ popd
|
|||||||
%files -n python3-%{name}
|
%files -n python3-%{name}
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%doc CREDITS.rst README.rst
|
%doc CREDITS.rst README.rst
|
||||||
|
%config(noreplace) %{_httpd_modconfdir}/*wsgi-python3.conf
|
||||||
%{_httpd_moddir}/mod_wsgi_python3.so
|
%{_httpd_moddir}/mod_wsgi_python3.so
|
||||||
%{python3_sitearch}/mod_wsgi-*.egg-info
|
%{python3_sitearch}/mod_wsgi-*.egg-info
|
||||||
%{python3_sitearch}/mod_wsgi
|
%{python3_sitearch}/mod_wsgi
|
||||||
%{_bindir}/mod_wsgi-express-3
|
%{_bindir}/mod_wsgi-express-3
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Feb 27 2021 zhaorenhai <zhaorenhai@hotmail.com> - 4.6.4-2
|
||||||
|
- Add configure file
|
||||||
|
|
||||||
* Thu Nov 19 2020 huanghaitao <huanghaitao8@huawei.com> - 4.6.4-1
|
* Thu Nov 19 2020 huanghaitao <huanghaitao8@huawei.com> - 4.6.4-1
|
||||||
- package init
|
- package init
|
||||||
|
|||||||
7
wsgi-python3.conf
Normal file
7
wsgi-python3.conf
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# NOTE: mod_wsgi_python3 can not coexist in the same apache process as
|
||||||
|
# mod_wsgi (python2). Only load if mod_wsgi is not already loaded.
|
||||||
|
|
||||||
|
<IfModule !wsgi_module>
|
||||||
|
LoadModule wsgi_module modules/mod_wsgi_python3.so
|
||||||
|
</IfModule>
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user