]> git.pld-linux.org Git - packages/nagios.git/commitdiff
- migrated to apache 2.4 auto/th/nagios-3.5.0-2 auto/ti/nagios-3.5.0-2
authorJan Rękorajski <baggins@pld-linux.org>
Thu, 16 May 2013 19:10:26 +0000 (21:10 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Thu, 16 May 2013 19:10:26 +0000 (21:10 +0200)
nagios-apache.conf
nagios-httpd.conf [new file with mode: 0644]
nagios.spec

index 57c2575d8b198f7fefe862b0ec849fbed08def1b..d79a87e6b386b5be334167a9de7cfbd2a0169746 100644 (file)
@@ -1,5 +1,3 @@
-# $Id$
-
 <Directory ~ "/usr/lib/nagios/cgi/|/usr/share/nagios/">
        Options ExecCGI
 
diff --git a/nagios-httpd.conf b/nagios-httpd.conf
new file mode 100644 (file)
index 0000000..f7baaec
--- /dev/null
@@ -0,0 +1,42 @@
+<Directory ~ "/usr/lib/nagios/cgi/|/usr/share/nagios/">
+       Options ExecCGI
+
+       # WITHOUT SSL
+       <IfModule !mod_ssl.c>
+               Require all denied
+               Require local
+       </IfModule>
+
+       # WITH SSL ENABLED
+       <IfModule mod_ssl.c>
+               SSLRequireSSL
+
+               Require all granted
+               AuthType Basic
+               AuthName "Nagios"
+
+               # LDAP based Authz. Apache 1.3
+               <IfModule mod_auth_ldap.c>
+                       AuthLDAPEnabled on
+                       AuthLDAPURL ldap://ldap.example.org/ou=People,dc=example,dc=org?uid?sub?(objectClass=*)
+               </IfModule>
+
+               AuthUserFile /etc/webapps/nagios/passwd
+               AuthGroupFile /etc/webapps/nagios/group
+               Require group nagios
+       </IfModule>
+</Directory>
+
+# We grant access to static images for everybody, as the files are available
+# publically anyway, but without having it with http password i'm able to link
+# icons to jabber notify messages :)
+<Directory /usr/share/nagios/images>
+       Require all granted
+</Directory>
+<Directory /usr/share/doc/nagios>
+       Require all granted
+</Directory>
+
+ScriptAlias /nagios/cgi-bin/ /usr/lib/nagios/cgi/
+Alias /nagios/docs/ /usr/share/doc/nagios/
+Alias /nagios/ /usr/share/nagios/
index 7d085245fe9db77486d43fffb9a142eeda03cfc8..862a2a4048791e91c7fa8a0bf2ab2be199f5dd4f 100644 (file)
@@ -12,7 +12,7 @@ Summary(pl.UTF-8):    Program do monitorowania serwerów/usług/sieci
 Summary(pt_BR.UTF-8):  Programa para monitoração de máquinas e serviços
 Name:          nagios
 Version:       3.5.0
-Release:       1
+Release:       2
 License:       GPL v2+
 Group:         Networking
 Source0:       http://downloads.sourceforge.net/nagios/nagios-3.x/%{name}-%{version}/%{name}-%{version}.tar.gz
@@ -29,6 +29,7 @@ Source7:      http://www.google.com/mapfiles/marker.png
 # Source7-md5: edefef4bdfc29e1c953694651f05b466
 Source8:       googlemap.js
 Source9:       %{name}wall.php
+Source10:      %{name}-httpd.conf
 Patch0:                %{name}-resources.patch
 Patch1:                %{name}-iconv-in-libc.patch
 Patch2:                %{name}-webapps.patch
@@ -152,6 +153,7 @@ Requires:   webserver(cgi)
 Requires:      webserver(indexfile)
 Suggests:      %{name}-doc
 Suggests:      php-magpierss >= 0.72
+Conflicts:     apache-base < 2.4.0-1
 
 %description cgi
 CGI webinterface for Nagios.
@@ -261,6 +263,7 @@ sed -i -e '
 ' p1.pl
 
 sed -e 's,%{_prefix}/lib/,%{_libdir}/,' %{SOURCE1} > apache.conf
+sed -e 's,%{_prefix}/lib/,%{_libdir}/,' %{SOURCE10} > httpd.conf
 sed -e 's,%{_prefix}/lib/,%{_libdir}/,' %{SOURCE5} > lighttpd.conf
 
 # fixup cgi config
@@ -351,7 +354,7 @@ done
 
 # webserver files
 cp -p apache.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/apache.conf
-cp -p apache.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf
+cp -p httpd.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf
 cp -p lighttpd.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/lighttpd.conf
 cp -p sample-config/cgi.cfg $RPM_BUILD_ROOT%{_webapps}/%{_webapp}
 cp -p %{SOURCE6} $RPM_BUILD_ROOT%{htmldir}/images
@@ -439,11 +442,11 @@ fi
 %triggerun cgi -- apache1 < 1.3.37-3, apache1-base
 %webapp_unregister apache %{_webapp}
 
-%triggerin cgi -- apache < 2.2.0, apache-base
+%triggerin cgi -- apache-base
 %addusertogroup http nagcmd
 %webapp_register httpd %{_webapp}
 
-%triggerun cgi -- apache < 2.2.0, apache-base
+%triggerun cgi -- apache-base
 %webapp_unregister httpd %{_webapp}
 
 %triggerin cgi -- lighttpd
This page took 0.044807 seconds and 4 git commands to generate.