]> git.pld-linux.org Git - packages/monit.git/blob - monit.spec
- offical patch to 4.8.1
[packages/monit.git] / monit.spec
1 Summary:        Process monitor and restart utility
2 Summary(pl):    Narzêdzie do monitorowania procesów i ich restartowania
3 Name:           monit
4 %define         _ver 4.8
5 Version:        %{_ver}.1
6 Release:        1
7 License:        GPL
8 Group:          Applications/Console
9 Source0:        http://www.tildeslash.com/monit/dist/%{name}-%{_ver}.tar.gz
10 # Source0-md5:  376bd526ee5577a6f0a842216f8ccf25
11 Source1:        %{name}.init
12 Patch0:         http://www.tildeslash.com/monit/dist/%{name}-4.8-patch01
13 URL:            http://www.tildeslash.com/monit/
14 BuildRequires:  bison
15 BuildRequires:  flex
16 BuildRequires:  openssl-devel >= 0.9.7d
17 BuildRequires:  rpmbuild(macros) >= 1.268
18 Requires(post,preun):   /sbin/chkconfig
19 Requires:       rc-scripts
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %description
23 monit is an utility for monitoring daemons or similar programs running
24 on a Unix system. It will start specified programs if they are not
25 running and restart programs not responding.
26
27 %description -l pl
28 monit jest narzêdziem do monitorowania demonów oraz podobnych
29 programów pracuj±cych w systemie Unix. monit zrestartuje podany
30 program w momencie gdy przestaje on pracowaæ lub w momencie gdy
31 program przestaje odpowiadaæ.
32
33 %prep
34 %setup -q -n %{name}-%{_ver}
35 %patch0 -p0
36
37 %build
38 %configure \
39         --with-ssl-lib-dir=%{_libdir}
40 %{__make}
41
42 %install
43 rm -rf $RPM_BUILD_ROOT
44 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,monit}
45
46 %{__make} install \
47         DESTDIR=$RPM_BUILD_ROOT
48
49 # include all files provided by services:
50 echo "include %{_sysconfdir}/monit/*.monitrc" >> monitrc.main
51
52 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
53 install monitrc.main $RPM_BUILD_ROOT%{_sysconfdir}/monitrc
54 install monitrc $RPM_BUILD_ROOT%{_sysconfdir}/monit/default.monitrc
55
56 %clean
57 rm -rf $RPM_BUILD_ROOT
58
59 %post
60 /sbin/chkconfig --add %{name}
61 %service monit restart "Monit Daemon"
62
63 %preun
64 if [ "$1" = "0" ]; then
65         %service monit stop
66         /sbin/chkconfig --del %{name}
67 fi
68
69 %files
70 %defattr(644,root,root,755)
71 %doc doc/*.html CHANGES.txt CONTRIBUTORS FAQ.txt README*
72 %attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}rc
73 %attr(751,root,root) %dir %{_sysconfdir}/monit
74 %attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/monit/*.monitrc
75 %attr(755,root,root) %{_bindir}/*
76 %attr(754,root,root) /etc/rc.d/init.d/%{name}
77 %{_mandir}/man?/*
This page took 0.04808 seconds and 3 git commands to generate.