/[smecontribs]/rpms/smeserver-nagios-nsca/contribs7/smeserver-nagios-nsca.spec
ViewVC logotype

Annotation of /rpms/smeserver-nagios-nsca/contribs7/smeserver-nagios-nsca.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.5 - (hide annotations) (download)
Tue Nov 25 16:20:27 2008 UTC (16 years ago) by slords
Branch: MAIN
Changes since 1.4: +0 -0 lines
Restore

1 slords 1.4 # $Id: smeserver-nagios-nsca.spec,v 1.3 2008/04/02 15:03:58 slords Exp $
2 slords 1.3 # Authority: mweinber
3     # Name: Michael Weinberger
4    
5 slords 1.1 Summary: Nagios nsca integration
6     %define name smeserver-nagios-nsca
7     Name: %{name}
8     %define version 1.0.1
9     %define release 0
10     Version: %{version}
11 slords 1.2 Release: %{release}%{?dist}
12 slords 1.1 License: GPL
13     Group: Applications/System
14     Source: %{name}-%{version}.tar.gz
15     BuildRoot: /var/tmp/%{name}-buildroot/
16     BuildArch: noarch
17     Requires: smeserver-release >= 7.1.3
18     Requires: nagios-nsca >= 2.6
19 slords 1.2 BuildRequires: e-smith-devtools
20 slords 1.1 AutoReq: no
21    
22     %changelog
23     * Thu Oct 1 2007 Michael Weinberger <mweinber@neddix.de>
24     - Initial release
25    
26     %description
27     Nagios nsca integration
28    
29     Setting the TCP wrapper allowed hosts:
30     config setprop nsca HostsAllow "127.0.0.1 10.203.104.0/255.255.252.0 172.22.32.0/255.255.240.0"
31     expand-template /etc/hosts.allow
32    
33    
34     %prep
35     %setup -q -n %{name}-%{version}
36    
37     %build
38    
39     %install
40     rm -rf $RPM_BUILD_ROOT
41     (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
42     rm -f %{name}-%{version}-filelist
43     /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
44     >> %{name}-%{version}-filelist
45     find $RPM_BUILD_ROOT -depth -type l -print |\
46     sed "s@^$RPM_BUILD_ROOT@@g" >> %{name}-%{version}-filelist
47    
48     %clean
49     rm -rf $RPM_BUILD_ROOT
50    
51     %post
52     /sbin/e-smith/config printtype nsca > /dev/null || /sbin/e-smith/config set nsca service
53     if [ "x`/bin/cat /proc/1/cmdline`" = "xinit [7]" ] ; then
54     /sbin/e-smith/expand-template /etc/hosts.allow
55     /sbin/e-smith/service nsca restart
56     fi
57    
58     %preun
59     if [ "x`/bin/cat /proc/1/cmdline`" = "xinit [7]" ] ; then
60     if [ $1 = 0 ] ; then # uninstall
61     /sbin/e-smith/service nsca stop
62     fi
63     fi
64    
65    
66     %postun
67     if [ "x`/bin/cat /proc/1/cmdline`" = "xinit [7]" ] ; then
68     if [ $1 = 0 ] ; then # uninstall
69     /sbin/e-smith/expand-template /etc/hosts.allow
70     fi
71     fi
72    
73     %files -f %{name}-%{version}-filelist
74     %defattr(-,root,root)

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed