Logoj0ke.net Open Build Service > Projects > home:netmax > nrpe > Changes
Sign Up | Log In

Changes of Revision 11

[-] Changed nrpe.spec
x
 
1
@@ -1,7 +1,7 @@
2
 #!BuildIgnore:          post-build-checks
3
 %define myname nrpe
4
 %define version 2.12
5
-%define release 1
6
+%define release 20
7
 %define nsusr nagios
8
 %define nsgrp nagios
9
 %define nsport 5666
10
@@ -13,21 +13,22 @@
11
 # Macro that print mesages to syslog at package (un)install time
12
 %define nnmmsg logger -t %{name}/rpm
13
 
14
-Summary: Host/service/network monitoring agent for Nagios
15
-URL: http://www.nagios.org
16
-Name: nagios-nrpe
17
-Version: %{version}
18
-Release: %{release}
19
-License: GPL
20
-Group: Application/System
21
-Source0: %{myname}-%{version}.tar.bz2
22
-Source1: %{myname}-rpmlintrc
23
-Patch0:    %{myname}-suse-init.patch
24
-BuildRoot: %{_tmppath}/%{name}-buildroot
25
-Prefix: %{_prefix}
26
-Prefix: /etc/init.d
27
-Prefix: /etc/nagios
28
-Requires: bash, grep, nagios-plugins
29
+Summary:   Host/service/network monitoring agent for Nagios
30
+URL:       http://www.nagios.org
31
+Name:      nagios-nrpe
32
+Version:   %{version}
33
+Release:   %{release}
34
+License:   GPL
35
+Group:     Application/System
36
+Source0:   %{myname}-%{version}.tar.bz2
37
+Source1:   %{myname}-rpmlintrc
38
+Patch0:        %{myname}-suse-init.patch
39
+Patch1:        %{myname}-config.patch
40
+BuildRoot: %{_tmppath}/%{name}-buildroot
41
+Prefix:        %{_prefix}
42
+Prefix:        /etc/init.d
43
+Prefix:        /etc/nagios
44
+Requires:  bash, grep, nagios-plugins
45
 %if 0%{?suse_version}
46
 PreReq: /bin/logger, sed, mktemp
47
 %endif
48
@@ -65,6 +66,7 @@
49
 %prep
50
 %setup -q -n %{myname}-%{version}
51
 %patch0
52
+%patch1
53
 
54
 %pre
55
 # Create `nagios' group on the system if necessary
56
@@ -112,6 +114,11 @@
57
    /sbin/service nrpe condrestart >/dev/null 2>&1 || :
58
 fi
59
 
60
+%post
61
+if [ -f /etc/sudoers ] ; then
62
+   echo "nagios          ALL=(ALL) NOPASSWD: /usr/lib/nagios/plugins/" >> /etc/sudoers
63
+fi
64
+
65
 %build
66
 export PATH=$PATH:/usr/sbin
67
 CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" \
68
@@ -137,6 +144,7 @@
69
 install -d -m 0755 ${RPM_BUILD_ROOT}/etc/init.d
70
 install -d -m 0755 ${RPM_BUILD_ROOT}/etc/xinetd.d
71
 install -d -m 0755 ${RPM_BUILD_ROOT}/etc/nagios
72
+install -d -m 0755 ${RPM_BUILD_ROOT}/etc/nagios/nrpe.d
73
 install -d -m 0755 ${RPM_BUILD_ROOT}/usr/sbin
74
 install -d -m 0755 ${RPM_BUILD_ROOT}/usr/lib/nagios/plugins
75
 
76
@@ -161,6 +169,7 @@
77
 %config(noreplace)/etc/xinetd.d/nrpe
78
 %{_prefix}/sbin/nrpe
79
 %dir /etc/nagios
80
+%dir /etc/nagios/nrpe.d/
81
 %defattr(644,root,root)
82
 %config(noreplace) /etc/nagios/*.cfg
83
 %defattr(644,%{nsusr},%{nsgrp})
84
@@ -173,6 +182,10 @@
85
 %doc Changelog LEGAL README
86
 
87
 %changelog
88
+* Tue Apr 20 2010 Carsten Schoene <cs@linux-administrator.com> - 2.12-20
89
+- added nrpe_local.cfg and nrpe.d directory to nrpe configuration
90
+- activated sudo by default
91
+
92
 * Tue Mar 11 2008 Carsten Schoene <cs@linux-administrator.com>
93
 - version bump to 2.12
94
  - Fix for unterminated multiline plugin (garbage) output (Krzysztof Oledzki)
95
[+] Added nrpe-config.patch ^