]> git.pld-linux.org Git - packages/demarc.git/blame - demarc.spec
use %service
[packages/demarc.git] / demarc.spec
CommitLineData
ece2866a
ER
1# TODO
2# - integrate pld webapps framework
09abfc3c
AM
3%define ver 1.05
4%define subver RC1
ece2866a 5%include /usr/lib/rpm/macros.perl
09abfc3c 6Summary: Network monitoring program
47ba4d14 7Summary(pl.UTF-8): Program do monitorowania sieci
09abfc3c
AM
8Name: demarc
9Version: %{ver}.%{subver}
d57978aa 10Release: 4
349f96ed 11License: http://www.demarc.org/license/ (Free for non-commercial use)
09abfc3c 12Group: Networking
349f96ed 13Source0: http://www.demarc.org/downloads/demarc-105/%{name}-%{ver}-%{subver}.tar.gz
85d00b83 14# Source0-md5: adf1550b8e7a4936c4b37ac214704f27
09abfc3c
AM
15Source1: %{name}-apache.conf
16Source2: %{name}.init
48965869 17Source3: %{name}.cron
09abfc3c 18Patch0: %{name}-config.patch
349f96ed 19Patch1: %{name}-whois-fix.patch
09abfc3c 20URL: http://www.demarc.org/
d57978aa 21BuildRequires: perl-Apache-DBI
09abfc3c
AM
22BuildRequires: perl-CGI
23BuildRequires: perl-DBI
09abfc3c 24BuildRequires: perl-Digest-MD5
d57978aa 25BuildRequires: perl-Msql-Mysql-modules
26BuildRequires: perl-devel >= 1:5.6
27BuildRequires: rpm-perlprov >= 4.1-13
ea1a0c4b 28BuildRequires: rpmbuild(macros) >= 1.228
0e9bdc22 29Requires(post,preun): /sbin/chkconfig
ece2866a 30Requires: crondaemon
155879fb
ER
31Requires: rc-scripts
32Requires: webserver = apache
09abfc3c
AM
33BuildArch: noarch
34BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
09abfc3c
AM
36%define _bindir %{_sbindir}
37
38%description
39DEMARC is an all-inclusive network monitoring program that allows you
40to monitor an entire network of servers from one powerful web
41interface.
42
43Instead of having one program perform file integrity checks, another
44program monitoring the connectivity and health of your network, and
45yet another monitoring your network for intrusion detection attempts,
46DEMARC combines all three services into one powerful client/server
47program. Not only can you monitor the status of the different machines
48in your network, but you can also respond to changes in your network
49all from one centralized location.
50
0e51d86f
JR
51%description -l pl.UTF-8
52DEMARC to kompletny system monitorowania sieci pozwalający monitorować
53całą sieć serwerów z jednego interfejsu WWW.
09abfc3c 54
0e51d86f
JR
55Zamiast posiadać jeden program sprawdzający integralność plików, inny
56program monitorujący połączenia i stan Twojej sieci, i jeszcze jeden
57program monitorujący sieć w celach detekcji intruzów wystarczy DEMARC
58łączący w sobie te trzy usługi w jednym programie klient/serwer. Nie
59tylko możesz monitorować stan różnych maszyn w Twojej sieci ale także
60możesz reagować na zmiany z jednej centralnej lokalizacji.
09abfc3c
AM
61
62%package client
349f96ed 63Summary: Network monitoring program - client
47ba4d14 64Summary(pl.UTF-8): Program do monitorowania sieci - klient
349f96ed 65Group: Networking
b4d6e872 66Requires: snort(mysql) >= 1.8.1
09abfc3c
AM
67
68%description client
69DEMARC is an all-inclusive network monitoring program that allows you
70to monitor an entire network of servers from one powerful web
71interface.
72
349f96ed
JB
73This is client program which should be installed on all monitored
74servers.
09abfc3c 75
0e51d86f
JR
76%description client -l pl.UTF-8
77DEMARC to kompletny system monitorowania sieci pozwalający monitorować
78całą sieć serwerów z jednego interfejsu WWW.
09abfc3c 79
0e51d86f 80To jest program kliencki, który powinien być zainstalowany na
349f96ed 81wszystkich monitorowanych serwerach.
09abfc3c
AM
82
83%prep
84%setup -q -n %{name}-%{ver}-%{subver}
85%patch0 -p1
349f96ed 86%patch1 -p1
09abfc3c
AM
87
88%install
89rm -rf $RPM_BUILD_ROOT
bcbf829e
PG
90install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,cron.d,demarcd,httpd} \
91 $RPM_BUILD_ROOT{%{_sbindir},%{_datadir}/demarc/{images,cgi}} \
92 $RPM_BUILD_ROOT%{_var}/lib/demarcd
09abfc3c 93
ece2866a
ER
94cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/%{name}.conf
95install -p %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/demarcd
96cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/cron.d/%{name}
97install -p bin/demarcd $RPM_BUILD_ROOT%{_sbindir}
98cp -p conf/* $RPM_BUILD_ROOT%{_sysconfdir}/demarcd
99cp -a cgi images $RPM_BUILD_ROOT%{_datadir}/demarc
100cp -p install/{c*,d*,p*} $RPM_BUILD_ROOT%{_datadir}/demarc
09abfc3c 101
09abfc3c
AM
102%clean
103rm -rf $RPM_BUILD_ROOT
104
105%post
349f96ed 106echo 'Remember to add "Include demarc.conf" to httpd.conf.'
09abfc3c
AM
107
108%post client
109if [ "$1" = "1" ] ; then
110 touch /var/log/demarcd && chmod 750 /var/log/demarcd
111fi
112/sbin/chkconfig --add demarcd
ea1a0c4b
ER
113%service demarcd restart
114%banner -e -o %{name} <<EOF
115
116Run "%{_sbindir}/demarcd -I" to install new snort sensor and then
117run "service demarcd start" to start demarcd daemon.
09abfc3c 118
ea1a0c4b
ER
119Note that in most cases there is no need to start "snort" as
120separate daemon, so turn it off using "chkconfig snort off".
121EOF
09abfc3c
AM
122
123%preun client
124if [ "$1" = "0" ] ; then
ea1a0c4b 125 %service demarcd stop
09abfc3c
AM
126 /sbin/chkconfig --del demarcd
127fi
128
129%files
130%defattr(644,root,root,755)
72d59f4d 131%doc install/{CHAN*,INS*,LIC*}
09abfc3c
AM
132%dir %{_datadir}/demarc
133%{_datadir}/demarc/create_mysql_demarc
134%{_datadir}/demarc/db_patch_queries
135%attr(755,root,root) %{_datadir}/demarc/*.pl
136
137%dir %{_datadir}/demarc/cgi
138%{_datadir}/demarc/cgi/StaticServices.pm
139%attr(640,root,http) %{_datadir}/demarc/cgi/DEMARC_config.pm
140%attr(755,root,root) %{_datadir}/demarc/cgi/demarc
141
142%dir %{_datadir}/demarc/cgi/templates
143%{_datadir}/demarc/cgi/templates/*
144
145%dir %{_datadir}/demarc/images
146%{_datadir}/demarc/images/*
147
b4d6e872 148%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd/demarc.conf
09abfc3c
AM
149
150%files client
151%defattr(644,root,root,755)
152%attr(754,root,root) /etc/rc.d/init.d/demarcd
153%attr(755,root,root) %{_sbindir}/demarcd
155879fb
ER
154%attr(750,root,root) %dir %{_sysconfdir}/demarcd
155%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/demarcd/*.conf
156%attr(750,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/demarcd/*.cmds
eec3ead5 157%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/cron.d/%{name}
860c2122 158%attr(750,root,root) %{_var}/lib/demarcd
This page took 0.097557 seconds and 4 git commands to generate.