Search
j0ke.net Open Build Service
>
Projects
>
home:jg
:
apachemods
>
mod_rpaf
> mod_rpaf.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File mod_rpaf.spec of Package mod_rpaf
%{!?apxs: %{expand:%%define apxs %{_sbindir}/apxs}} %define moduledir %{expand:%(%{apxs} -q LIBEXECDIR 2>/dev/null)} Name: mod_rpaf Version: 0.6 Release: 1 Summary: Reverse proxy add forward module for Apache Group: System Environment/Daemons License: ASL 1.0 URL: http://stderr.net/apache/rpaf/ Source0: http://stderr.net/apache/rpaf/download/%{name}-%{version}.tar.gz Source1: %{name}.conf BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: httpd-devel Requires: httpd-mmn = %(cat $(%{apxs} -q INCLUDEDIR)/.mmn || echo ERROR) %description mod_rpaf changes the remote address of the client visible to other Apache modules when two conditions are satisfied. First condition is that the remote client is actually a proxy that is defined in httpd.conf. Secondly if there is an incoming X-Forwarded-For header and the proxy is in it's list of known proxies it takes the last IP from the incoming X-Forwarded-For header and changes the remote address of the client in the request structure. It also takes the incoming X-Host header and updates the virtualhost settings accordingly. For Apache2 mod_proxy it takes the X-Forwared-Host header and updates the virtualhosts. %prep %setup -q f=README ; iconv -f iso-8859-1 -t utf-8 $f > $f.utf8 ; mv $f.utf8 $f %build make %{?_smp_mflags} APXS2=%{apxs} rpaf-2.0 %install rm -rf $RPM_BUILD_ROOT install -dm 755 $RPM_BUILD_ROOT%{moduledir} install -pm 755 .libs/mod_rpaf-2.0.so $RPM_BUILD_ROOT%{moduledir}/mod_rpaf.so install -Dpm 644 %{SOURCE1} \ $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/00-rpaf.conf %clean rm -rf $RPM_BUILD_ROOT %post [ $1 -eq 1 ] && %{_initrddir}/httpd condrestart >/dev/null || : %postun %{_initrddir}/httpd condrestart >/dev/null || : %files %defattr(-,root,root,-) %doc CHANGES README %config(noreplace) %{_sysconfdir}/httpd/conf.d/00-rpaf.conf %{moduledir}/mod_rpaf.so %changelog * Wed Jan 2 2008 Ville Skyttä <ville.skytta at iki.fi> - 0.6-0.1 - 0.6. * Fri May 25 2007 Ville Skyttä <ville.skytta at iki.fi> - 0.5-0.5 - Convert docs to UTF-8. * Sat Sep 30 2006 Ville Skyttä <ville.skytta at iki.fi> - 0.5-0.4 - Rebuild. * Mon Mar 20 2006 Ville Skyttä <ville.skytta at iki.fi> - 0.5-0.3 - Rebuild. * Sat Jun 4 2005 Ville Skyttä <ville.skytta at iki.fi> - 0.5-0.2 - Rebuild for FC4. * Tue May 24 2005 Ville Skyttä <ville.skytta at iki.fi> - 0.5-0.1 - Drop Apache 1.x compatibility, require httpd-mmn. * Sun May 2 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:0.5-0.fdr.1 - First build.