packages: nagios/nagios.spec, nagios/cgi.cfg.patch (NEW) - use upstream cgi...

glen glen at pld-linux.org
Mon Aug 3 17:38:13 CEST 2009


Author: glen                         Date: Mon Aug  3 15:38:13 2009 GMT
Module: packages                      Tag: HEAD
---- Log message:
- use upstream cgi.cfg as base

---- Files affected:
packages/nagios:
   nagios.spec (1.125 -> 1.126) , cgi.cfg.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/nagios/nagios.spec
diff -u packages/nagios/nagios.spec:1.125 packages/nagios/nagios.spec:1.126
--- packages/nagios/nagios.spec:1.125	Sat Jul 25 21:47:09 2009
+++ packages/nagios/nagios.spec	Mon Aug  3 17:38:08 2009
@@ -28,6 +28,7 @@
 Patch2:		%{name}-webapps.patch
 Patch3:		%{name}-cgi-http_charset.patch
 Patch4:		%{name}-cmd-typo.patch
+Patch5:		cgi.cfg.patch
 URL:		http://www.nagios.org/
 BuildRequires:	autoconf
 BuildRequires:	automake
@@ -180,6 +181,7 @@
 %patch2 -p1
 %patch3 -p1
 %patch4 -p1
+%patch5 -p1
 
 sed -i -e '
 	s,".*/var/rw/nagios.cmd,"%{_localstatedir}/rw/nagios.cmd,
@@ -189,6 +191,16 @@
 sed -e 's,%{_prefix}/lib/,%{_libdir}/,' %{SOURCE1} > apache.conf
 sed -e 's,%{_prefix}/lib/,%{_libdir}/,' %{SOURCE6} > lighttpd.conf
 
+# fixup cgi config
+%{__sed} -i -e '
+	# kill trailing spaces
+	s, \+$,,
+	# use real paths
+	s,/usr/local/nagios/share, at datadir@,g
+	# we want all authorized users have default access
+	s,=nagiosadmin,=*,g
+' sample-config/cgi.cfg.in
+
 %build
 cp -f /usr/share/automake/config.sub .
 %{__aclocal}
@@ -240,7 +252,8 @@
 install apache.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/apache.conf
 install apache.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf
 install lighttpd.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/lighttpd.conf
-mv $RPM_BUILD_ROOT{%{_sysconfdir}/cgi.cfg,%{_webapps}/%{_webapp}}
+rm $RPM_BUILD_ROOT%{_sysconfdir}/cgi.cfg
+cp -a sample-config/cgi.cfg $RPM_BUILD_ROOT%{_webapps}/%{_webapp}
 > $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/passwd
 echo 'nagios:' > $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/group
 
@@ -504,6 +517,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.126  2009/08/03 15:38:08  glen
+- use upstream cgi.cfg as base
+
 Revision 1.125  2009/07/25 19:47:09  glen
 - release 2
 

================================================================
Index: packages/nagios/cgi.cfg.patch
diff -u /dev/null packages/nagios/cgi.cfg.patch:1.1
--- /dev/null	Mon Aug  3 17:38:13 2009
+++ packages/nagios/cgi.cfg.patch	Mon Aug  3 17:38:08 2009
@@ -0,0 +1,38 @@
+--- nagios-3.1.2/sample-config/cgi.cfg.in	2009-08-03 18:30:03.896753761 +0300
++++ svn/nagios-config/trunk/cgi.cfg	2009-08-03 18:25:38.142614386 +0300
+@@ -1,8 +1,6 @@
+ #################################################################
+ #
+-# CGI.CFG - Sample CGI Configuration File for Nagios @VERSION@
+-#
+-# Last Modified: 06-17-2009
++# CGI.CFG - CGI Configuration File for Nagios
+ #
+ #################################################################
+ 
+@@ -46,9 +45,9 @@
+ # This option determines whether or not a context-sensitive
+ # help icon will be displayed for most of the CGIs.
+ # Values: 0 = disables context-sensitive help
+ #         1 = enables context-sensitive help
+ 
+-show_context_help=0
++show_context_help=1
+ 
+ 
+ 
+@@ -269,7 +233,7 @@
+ # OS and distribution, so you may have to tweak this to
+ # work on your system.
+ 
+-ping_syntax=/bin/ping -n -U -c 5 $HOSTADDRESS$
++ping_syntax=/usr/bin/ping -n -U -c 5 $HOSTADDRESS$
+ 
+ 
+ 
+@@ -359,4 +323,4 @@
+ #splunk_url=http://127.0.0.1:8000/
+ 
+ 
+-
++# vim:ts=8:sw=8:syn=cfg
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/nagios.spec?r1=1.125&r2=1.126&f=u



More information about the pld-cvs-commit mailing list