1 Summary: Simple BIND statistics
2 Summary(pl.UTF-8): Proste statystyki dla BINDa
7 Group: Applications/Networking
8 Source0: http://dl.sourceforge.net/dnsgraph/%{name}-%{version}.tar.gz
9 # Source0-md5: 4847627fb3709bbe166d59e872225693
12 URL: http://dnsgraph.sourceforge.net/
13 BuildRequires: rpm-perlprov
14 Requires(post,preun): grep
15 Requires(preun): fileutils
17 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19 %define _dnsgraphdir %{_datadir}/%{name}
22 Dnsgraph is a very simple DNS statistics RRDtool frontend for Bind
23 (named) that produces daily, weekly, monthly, and yearly graphs of
24 success/failure, recursion/referral, nxrrset/nxdomain.
26 %description -l pl.UTF-8
27 dnsgraph to bardzo prosty frontend dla RRDtoola do statystyk DNS dla
28 Binda (named) tworzący dzienne, tygodniowe, miesięczne i roczne
29 wykresy powodzeń/niepowodzeń, rekurencji/odniesień, nxrrset/nxdomain.
35 rm -rf $RPM_BUILD_ROOT
36 install -d $RPM_BUILD_ROOT{/etc/{cron.d,httpd},%{_dnsgraphdir}/html/imgs}
38 install dnsanalise.pl dnsreport.pl $RPM_BUILD_ROOT%{_dnsgraphdir}
40 install %{SOURCE1} $RPM_BUILD_ROOT/etc/cron.d/%{name}
41 install %{SOURCE2} $RPM_BUILD_ROOT/etc/httpd
44 rm -rf $RPM_BUILD_ROOT
47 if [ -f /etc/httpd/httpd.conf ] && \
48 ! grep -q "^Include.*/%{name}.conf" /etc/httpd/httpd.conf; then
49 echo "Include /etc/httpd/%{name}.conf" >> /etc/httpd/httpd.conf
50 if [ -f /var/lock/subsys/httpd ]; then
56 if [ "$1" = "0" ]; then
58 grep -E -v "^Include.*%{name}.conf" /etc/httpd/httpd.conf > \
59 /etc/httpd/httpd.conf.tmp
60 mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
61 if [ -f /var/lock/subsys/httpd ]; then
67 %defattr(644,root,root,755)
70 %{_sysconfdir}/httpd/%{name}.conf
73 %attr(755,root,root) %{_dnsgraphdir}/dns*.pl