From e71a3f814f8a6e333f03bc2370c0de8614896da6 Mon Sep 17 00:00:00 2001 From: Athmane Madjoudj Date: Mar 17 2015 17:32:47 +0000 Subject: Initial import (rhbz #1089561) --- diff --git a/.gitignore b/.gitignore index e69de29..e9523a6 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/mod_ruid2-0.9.8.tar.bz2 diff --git a/10-mod_ruid2.conf b/10-mod_ruid2.conf new file mode 100644 index 0000000..0497606 --- /dev/null +++ b/10-mod_ruid2.conf @@ -0,0 +1,3 @@ +LoadModule ruid2_module modules/mod_ruid2.so + + diff --git a/mod_ruid2.conf b/mod_ruid2.conf new file mode 100644 index 0000000..de2f43a --- /dev/null +++ b/mod_ruid2.conf @@ -0,0 +1,41 @@ +### EXAMPLE: +# +# +# User apache +# Group apache +# RMode stat +# RGroups apachetmp +# RDocumentChRoot /home /example.com/public_html +# +# NameVirtualHost 192.168.0.1 +# +# ServerAdmin webmaster@example.com +# RDocumentChRoot /home /example.com/public_html +# ServerName example.com +# ServerAlias www.example.com +# RMode config# unnecessary since config is the default +# RUidGid user1 group1 +# RGroups apachetmp +# +# +# RMode stat +# +# +# +# RMode config +# RUidGid user2 group2 +# RGroups groups1 +# +# +# +# RUidGid user3 group3 +# +# +# +# RMode config +# RUidGid user4 user4 +# RGroups groups4 +# +# +# +# diff --git a/mod_ruid2.spec b/mod_ruid2.spec new file mode 100644 index 0000000..3a12313 --- /dev/null +++ b/mod_ruid2.spec @@ -0,0 +1,73 @@ +%{!?_httpd_apxs: %{expand: %%global _httpd_apxs %%{_sbindir}/apxs}} +%{!?_httpd_mmn: %{expand: %%global _httpd_mmn %%(cat %{_includedir}/httpd/.mmn || echo missing-httpd-devel)}} +%{!?_httpd_confdir: %{expand: %%global _httpd_confdir %%{_sysconfdir}/httpd/conf.d}} +# /etc/httpd/conf.d with httpd < 2.4 and defined as /etc/httpd/conf.modules.d with httpd >= 2.4 +%{!?_httpd_modconfdir: %{expand: %%global _httpd_modconfdir %%{_sysconfdir}/httpd/conf.d}} +%{!?_httpd_moddir: %{expand: %%global _httpd_moddir %%{_libdir}/httpd/modules}} + + +Name: mod_ruid2 +Version: 0.9.8 +Release: 2%{?dist} +Summary: A suexec module for Apache + +License: ASL 2.0 +URL: http://sourceforge.net/projects/mod-ruid/ +Source0: http://downloads.sourceforge.net/project/mod-ruid/mod_ruid2/mod_ruid2-%{version}.tar.bz2 +Source1: mod_ruid2.conf +Source2: 10-mod_ruid2.conf + +BuildRequires: httpd-devel libcap-devel + +Requires: httpd +Requires: httpd-mmn = %{_httpd_mmn} + +%description +mod_ruid2 is a suexec module for Apache which takes advantage of +POSIX.1e capabilities to increase performance. + +%prep +%setup -q + + +%build +apxs -l cap -c %{name}.c + + +%install +mkdir -p %{buildroot}%{_httpd_confdir} +mkdir -p %{buildroot}%{_libdir}/httpd/modules +install -m 700 -d %{buildroot}%{_localstatedir}/lib/%{name} + +%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}" +# 2.4-style +install -Dp -m0644 %{SOURCE2} %{buildroot}%{_httpd_modconfdir}/10-mod_ruid2.conf +install -Dp -m0644 %{SOURCE1} %{buildroot}%{_httpd_confdir}/mod_ruid2.conf +%else +# 2.2-style +install -d -m0755 %{buildroot}%{_httpd_confdir} +cat %{SOURCE2} %{SOURCE1} > %{buildroot}%{_httpd_confdir}/mod_ruid2.conf +%endif +install -m 755 .libs/mod_ruid2.so %{buildroot}%{_httpd_moddir} + + +%files +%doc README +%{_httpd_moddir}/mod_ruid2.so +%config(noreplace) %{_httpd_confdir}/*.conf + +%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}" + %config(noreplace) %{_httpd_modconfdir}/*.conf +%endif + +%{!?_licensedir:%global license %%doc} +%license LICENSE + +%changelog +* Mon Mar 16 2015 Athmane Madjoudj 0.9.8-2 +- Fix license issue +- Add a workarround for epel + +* Sun Apr 20 2014 Athmane Madjoudj 0.9.8-1 +- Initial spec. + diff --git a/sources b/sources index e69de29..088d412 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +05a29e38ef22f4d5e8bf22b53f45ab41 mod_ruid2-0.9.8.tar.bz2