1 Summary: Bandwidth & Request Throttling
2 Name: apache-mod_throttle
6 Group: Networking/Daemons
7 Group(de): Netzwerkwesen/Server
8 Group(pl): Sieciowe/Serwery
9 Source0: http://www.snert.com/Software/mod_throttle/mod_throttle312.tgz
10 URL: http://www.snert.com/Software/mod_throttle/
11 BuildRequires: apache-devel
12 Requires: apache >= 1.3.1
13 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
15 %define _libexecdir %{_libdir}/apache
16 %define _htmldocdir /home/httpd/manual/mod
19 This Apache module is intended to reduce the load on your server &
20 bandwidth generated by popular virtual hosts, directories, locations,
21 or users according to supported polices (see below) that decide when
22 to delay or refuse requests. Also mod_throttle can track and throttle
23 incoming connections by IP address or by authenticated remote user.
26 %setup -q -n mod_throttle-%{version}
29 apxs -D SUEXEC_BIN="\"\\\"%{_sbindir}/suexec\\\"\"" -o mod_throttle.so -c *.c
30 # to don't bother about ssi counter inside
31 mv index.shtml index.html
34 rm -rf $RPM_BUILD_ROOT
35 install -d $RPM_BUILD_ROOT{%{_libexecdir},%{_htmldocdir}}
37 install mod_throttle.so $RPM_BUILD_ROOT%{_libexecdir}
38 install *.html $RPM_BUILD_ROOT%{_htmldocdir}
43 %{_sbindir}/apxs -e -a -n throttle %{_libexecdir}/mod_throttle.so 1>&2
44 if [ -f /var/lock/subsys/httpd ]; then
45 /etc/rc.d/init.d/httpd restart 1>&2
47 echo "Run \"/etc/rc.d/init.d/httpd start\" to start apache http daemon."
51 if [ "$1" = "0" ]; then
52 %{_sbindir}/apxs -e -A -n throttle %{_libexecdir}/mod_throttle.so 1>&2
53 if [ -f /var/lock/subsys/httpd ]; then
54 /etc/rc.d/init.d/httpd restart 1>&2
59 rm -rf $RPM_BUILD_ROOT
62 %defattr(644,root,root,755)
64 %doc %{_htmldocdir}/index.html
65 %attr(755,root,root) %{_libexecdir}/*