svn commit: r353152 - in head/net-mgmt/nagios4: . files
Mathieu Arnold
mat at FreeBSD.org
Wed May 7 12:56:32 UTC 2014
Author: mat
Date: Wed May 7 12:56:30 2014
New Revision: 353152
URL: http://svnweb.freebsd.org/changeset/ports/353152
QAT: https://qat.redports.org/buildarchive/r353152/
Log:
Update to 4.0.6
Pet portlint and rclint, cleanup SUB_LIST/PLIST_SUB.
Changelog: http://www.nagios.org/projects/nagioscore/history/nagios-4-version-history
Sponsored by: Absolight
Modified:
head/net-mgmt/nagios4/Makefile
head/net-mgmt/nagios4/distinfo
head/net-mgmt/nagios4/files/nagios.in
head/net-mgmt/nagios4/files/patch-configure.in
head/net-mgmt/nagios4/files/patch-html__Makefile.in
head/net-mgmt/nagios4/files/patch-html__main.php
head/net-mgmt/nagios4/files/pkg-message.in
head/net-mgmt/nagios4/pkg-plist
Modified: head/net-mgmt/nagios4/Makefile
==============================================================================
--- head/net-mgmt/nagios4/Makefile Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/Makefile Wed May 7 12:56:30 2014 (r353152)
@@ -2,10 +2,10 @@
# $FreeBSD$
PORTNAME= nagios
-PORTVERSION= 4.0.5
-PKGNAMESUFFIX= 4
+PORTVERSION= 4.0.6
CATEGORIES= net-mgmt
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}-4.x/${PORTNAME}-${PORTVERSION}
+PKGNAMESUFFIX= 4
MAINTAINER= mat at FreeBSD.org
COMMENT= Powerful network monitoring system
@@ -20,7 +20,7 @@ USE_AUTOTOOLS= autoconf libltdl
USE_PHP= xml
USE_RC_SUBR= nagios
-CONFLICTS= nagios-[12].* nagios-devel-*
+CONFLICTS= nagios-[123].* nagios-devel-*
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-command-user=${NAGIOSUSER} \
@@ -50,16 +50,16 @@ PLIST_SUB= NAGIOSDIR=${NAGIOSDIR} \
NAGIOSWWWDIR=${NAGIOSWWWDIR} \
NAGIOSUSER=${NAGIOSUSER} \
NAGIOSGROUP=${NAGIOSGROUP} \
- NAGIOSHTMURL=${NAGIOSHTMURL} \
- NAGIOSCGIURL=${NAGIOSCGIURL} \
WWWGRP=${WWWGRP}
+SUB_LIST= NAGIOSDIR=${NAGIOSDIR} \
+ NAGIOSWWWDIR=${PREFIX}/${NAGIOSWWWDIR} \
+ NAGIOSUSER=${NAGIOSUSER} \
+ NAGIOSGROUP=${NAGIOSGROUP} \
+ NAGIOSHTMURL=${NAGIOSHTMURL} \
+ NAGIOSCGIURL=${NAGIOSCGIURL}
SUB_FILES= pkg-message
-# XXX: Don't remove PREFIX from SUB_LIST here.
-SUB_LIST= PREFIX=${PREFIX} \
- ${PLIST_SUB}
-
NAGIOSUSER?= nagios
NAGIOSGROUP?= nagios
NAGIOSDIR?= /var/spool/nagios
Modified: head/net-mgmt/nagios4/distinfo
==============================================================================
--- head/net-mgmt/nagios4/distinfo Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/distinfo Wed May 7 12:56:30 2014 (r353152)
@@ -1,2 +1,2 @@
-SHA256 (nagios-4.0.5.tar.gz) = ad790bebadda8cc04daf639d1866864081849305fdf92dc0243b6d6246d3da3c
-SIZE (nagios-4.0.5.tar.gz) = 1793038
+SHA256 (nagios-4.0.6.tar.gz) = d400190c771eb90e0ba16351f6358fa7e22e42a7be986f2066db63518a14397b
+SIZE (nagios-4.0.6.tar.gz) = 1796012
Modified: head/net-mgmt/nagios4/files/nagios.in
==============================================================================
--- head/net-mgmt/nagios4/files/nagios.in Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/files/nagios.in Wed May 7 12:56:30 2014 (r353152)
@@ -14,37 +14,37 @@
# nagios_precache (bool): Set to "NO" by default.
# Set it to "YES" to enable pre-caching.
# nagios_flags (str): Set to "" by default.
-# nagios_configfile (str): Set to "%%PREFIX%%/etc/nagios/nagios.cfg" by default.
+# nagios_configfile (str): Set to "%%ETCDIR%%/nagios.cfg" by default.
#
. /etc/rc.subr
-name="nagios"
+name=nagios
rcvar=nagios_enable
-command="%%PREFIX%%/bin/nagios"
-command_args="-d"
-extra_commands="reload configtest"
-pidfile="%%NAGIOSDIR%%/nagios.lock"
-nagios_user="%%NAGIOSUSER%%"
-
-start_precmd="start_precmd"
-stop_postcmd="stop_postcmd"
-restart_precmd="nagios_checkconfig"
-reload_precmd="reload_precmd"
-configtest_cmd="nagios_checkconfig"
-sig_reload=HUP
-
load_rc_config "${name}"
-[ -z "${nagios_enable}" ] && nagios_enable="NO"
-[ -z "${nagios_configfile}" ] && nagios_configfile="%%PREFIX%%/etc/nagios/nagios.cfg"
-[ -z "${nagios_precache}" ] && nagios_precache="NO"
+start_precmd=start_precmd
+stop_postcmd=stop_postcmd
+restart_precmd=nagios_checkconfig
+reload_precmd=reload_precmd
+configtest_cmd=nagios_checkconfig
+sig_reload=HUP
+
+nagios_program=${nagios_program:-"%%PREFIX%%/bin/nagios"} # Path to named, if you want a different one.
+command_args=${command_args:-"-d"}
+extra_commands=${extra_commands:-"reload configtest"}
+pidfile=${pidfile:-"%%NAGIOSDIR%%/nagios.lock"}
+nagios_user=${nagios_user:-"%%NAGIOSUSER%%"}
+nagios_group=${nagios_group:-"%%NAGIOSGROUP%%"}
+nagios_configfile=${nagios_configfile:-"%%ETCDIR%%/nagios.cfg"}
+nagios_precache=${nagios_precache:-"NO"}
required_files="${nagios_configfile}"
command_args="${command_args} ${nagios_configfile}"
-nagios_cacheconfig() {
+nagios_cacheconfig()
+{
if ! checkyesno nagios_precache; then
return 0
fi
@@ -61,7 +61,8 @@ nagios_cacheconfig() {
fi
}
-nagios_checkconfig() {
+nagios_checkconfig()
+{
echo -n "Performing sanity check of nagios configuration: "
${command} -v ${nagios_configfile} 2>&1 >/dev/null
if [ $? != 0 ]; then
@@ -73,7 +74,8 @@ nagios_checkconfig() {
fi
}
-reload_precmd() {
+reload_precmd()
+{
if ! nagios_checkconfig; then
return 1
fi
@@ -83,7 +85,8 @@ reload_precmd() {
fi
}
-start_precmd() {
+start_precmd()
+{
if ! nagios_checkconfig; then
return 1
fi
@@ -96,7 +99,8 @@ start_precmd() {
rm -f "%%NAGIOSDIR%%/rw/nagios.cmd"
}
-stop_postcmd() {
+stop_postcmd()
+{
rm -f "%%NAGIOSDIR%%/nagios.tmp" "%%NAGIOSDIR%%/rw/nagios.cmd"
}
Modified: head/net-mgmt/nagios4/files/patch-configure.in
==============================================================================
--- head/net-mgmt/nagios4/files/patch-configure.in Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/files/patch-configure.in Wed May 7 12:56:30 2014 (r353152)
@@ -1,5 +1,5 @@
---- ./configure.in.orig 2014-04-11 20:37:42.000000000 +0200
-+++ ./configure.in 2014-04-15 15:19:42.000000000 +0200
+--- ./configure.in.orig 2014-04-29 17:55:49.000000000 +0200
++++ ./configure.in 2014-05-06 15:38:27.000000000 +0200
@@ -6,7 +6,6 @@
AC_INIT(base/nagios.c)
@@ -7,7 +7,7 @@
-AC_PREFIX_DEFAULT(/usr/local/nagios)
PKG_NAME=nagios
- PKG_VERSION="4.0.5"
+ PKG_VERSION="4.0.6"
@@ -134,14 +133,14 @@
AC_SUBST(nagios_grp)
AC_DEFINE_UNQUOTED(DEFAULT_NAGIOS_USER,"$nagios_user",[user name to run nagios])
Modified: head/net-mgmt/nagios4/files/patch-html__Makefile.in
==============================================================================
--- head/net-mgmt/nagios4/files/patch-html__Makefile.in Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/files/patch-html__Makefile.in Wed May 7 12:56:30 2014 (r353152)
@@ -1,6 +1,6 @@
---- ./html/Makefile.in.orig 2014-03-14 18:24:57.000000000 +0100
-+++ ./html/Makefile.in 2014-03-15 20:44:57.000000000 +0100
-@@ -35,56 +35,56 @@
+--- ./html/Makefile.in.orig 2014-04-29 17:55:49.000000000 +0200
++++ ./html/Makefile.in 2014-05-06 15:38:27.000000000 +0200
+@@ -35,58 +35,58 @@
devclean: distclean
install:
@@ -39,7 +39,11 @@
rm -f $(DESTDIR)$(HTMLDIR)/main.html
rm -f $(DESTDIR)$(HTMLDIR)/side.html
- $(INSTALL) -m 664 $(INSTALL_OPTS) jsonquery.html $(DESTDIR)$(HTMLDIR)
+- $(INSTALL) -m 664 $(INSTALL_OPTS) rss-corefeed.html $(DESTDIR)$(HTMLDIR)
+- $(INSTALL) -m 664 $(INSTALL_OPTS) rss-newsfeed.html $(DESTDIR)$(HTMLDIR)
+ $(INSTALL) -m 644 $(INSTALL_OPTS) jsonquery.html $(DESTDIR)$(HTMLDIR)
++ $(INSTALL) -m 644 $(INSTALL_OPTS) rss-corefeed.html $(DESTDIR)$(HTMLDIR)
++ $(INSTALL) -m 644 $(INSTALL_OPTS) rss-newsfeed.html $(DESTDIR)$(HTMLDIR)
for file in *.php; \
- do $(INSTALL) -m 664 $(INSTALL_OPTS) $$file $(DESTDIR)$(HTMLDIR); done
+ do $(INSTALL) -m 644 $(INSTALL_OPTS) $$file $(DESTDIR)$(HTMLDIR); done
Modified: head/net-mgmt/nagios4/files/patch-html__main.php
==============================================================================
--- head/net-mgmt/nagios4/files/patch-html__main.php Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/files/patch-html__main.php Wed May 7 12:56:30 2014 (r353152)
@@ -1,41 +1,34 @@
---- ./html/main.php.orig 2014-04-11 20:37:42.000000000 +0200
-+++ ./html/main.php 2014-04-15 15:20:13.000000000 +0200
-@@ -40,38 +40,10 @@
- <div class="product">Nagios<sup><span style="font-size: small;">®</span></sup> Core<sup><span style="font-size: small;">™</span></sup></div>
- <div class="version">Version 4.0.5</div>
- <div class="releasedate">April 11, 2014</div>
--<div class="checkforupdates"><a href="http://www.nagios.org/checkforupdates/?version=4.0.5&product=nagioscore" target="_blank">Check for updates</a></div>
- <!--<div class="whatsnew"><a href="http://go.nagios.com/nagioscore/whatsnew">Read what's new in Nagios Core 3</a></div>-->
- </div>
-
-
+--- ./html/main.php.orig 2014-04-29 17:55:49.000000000 +0200
++++ ./html/main.php 2014-05-06 15:39:05.000000000 +0200
+@@ -130,31 +130,6 @@
+ <div class="product">Nagios<sup><span style="font-size: small;">®</span></sup> Core<sup><span style="font-size: small;">™</span></sup></div>
+ <div class="version">Version 4.0.6</div>
+ <div class="releasedate">April 29, 2014</div>
+- <div class="checkforupdates"><a href="http://www.nagios.org/checkforupdates/?version=4.0.6&product=nagioscore" target="_blank">Check for updates</a></div>
+-</div>
+-
+-
-<div id="updateversioninfo">
-<?php
-- $updateinfo=get_update_information();
-- //print_r($updateinfo);
-- //$updateinfo['update_checks_enabled']=false;
-- //$updateinfo['update_available']=true;
-- if($updateinfo['update_checks_enabled']==false){
+- $updateinfo = get_update_information();
+- if (!$updateinfo['update_checks_enabled']) {
-?>
- <div class="updatechecksdisabled">
-- <div class="warningmessage">Warning: Automatic Update Checks are Disabled!</div>
-- <div class="submessage">Disabling update checks presents a possible security risk. Visit <a href="http://www.nagios.org/" target="_blank">nagios.org</a> to check for updates manually or enable update checks in your Nagios config file.</a></div>
+- <div class="warningmessage">Warning: Automatic Update Checks are Disabled!</div>
+- <div class="submessage">Disabling update checks presents a possible security risk. Visit <a href="http://www.nagios.org/" target="_blank">nagios.org</a> to check for updates manually or enable update checks in your Nagios config file.</a></div>
- </div>
-<?php
-- }
-- else if($updateinfo['update_available']==true && $this_version!=$updateinfo['update_version']){
+- } else if (
+- $updateinfo['update_available'] && $this_version < $updateinfo['update_version']
+- ) {
-?>
- <div class="updateavailable">
-- <div class="updatemessage">A new version of Nagios Core is available!</div>
-- <div class="submessage">Visit <a href="http://www.nagios.org/download/" target="_blank">nagios.org</a> to download Nagios <?php echo $updateinfo['update_version'];?>.</div>
+- <div class="updatemessage">A new version of Nagios Core is available!</div>
+- <div class="submessage">Visit <a href="http://www.nagios.org/download/" target="_blank">nagios.org</a> to download Nagios <?php echo $updateinfo['update_version'];?>.</div>
- </div>
-<?php
-- }
+- }
-?>
--</div>
--
--
--
- <div id="splashboxes">
- <div id='topsplashbox'>
- <div id="splashbox1" class="splashbox">
+ </div>
+
+
Modified: head/net-mgmt/nagios4/files/pkg-message.in
==============================================================================
--- head/net-mgmt/nagios4/files/pkg-message.in Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/files/pkg-message.in Wed May 7 12:56:30 2014 (r353152)
@@ -4,29 +4,29 @@
nagios_enable="YES"
- Configuration templates are available in %%PREFIX%%/etc/nagios as
+ Configuration templates are available in %%ETCDIR%% as
*.cfg-sample files. Copy them to *.cfg files where required and
edit to suit your needs. Documentation is available in HTML form
- in %%PREFIX%%/%%NAGIOSWWWDIR%%/docs.
+ in %%NAGIOSWWWDIR%%/docs.
If you don't already have a web server running, you will need to
install and configure one to finish off your Nagios installation.
When used with Apache, the following should be sufficient to publish
the web component of Nagios (modify the allow list to suit):
- <Directory %%PREFIX%%/%%NAGIOSWWWDIR%%>
+ <Directory %%NAGIOSWWWDIR%%>
Order deny,allow
Deny from all
Allow from 127.0.0.1
php_flag engine on
- php_admin_value open_basedir %%PREFIX%%/%%NAGIOSWWWDIR%%/:%%NAGIOSDIR%%/
+ php_admin_value open_basedir %%NAGIOSWWWDIR%%/:%%NAGIOSDIR%%/
</Directory>
- <Directory %%PREFIX%%/%%NAGIOSWWWDIR%%/cgi-bin>
+ <Directory %%NAGIOSWWWDIR%%/cgi-bin>
Options ExecCGI
</Directory>
- ScriptAlias %%NAGIOSCGIURL%%/ %%PREFIX%%/%%NAGIOSWWWDIR%%/cgi-bin/
- Alias %%NAGIOSHTMURL%%/ %%PREFIX%%/%%NAGIOSWWWDIR%%/
+ ScriptAlias %%NAGIOSCGIURL%%/ %%NAGIOSWWWDIR%%/cgi-bin/
+ Alias %%NAGIOSHTMURL%%/ %%NAGIOSWWWDIR%%/
**********************************************************************
Modified: head/net-mgmt/nagios4/pkg-plist
==============================================================================
--- head/net-mgmt/nagios4/pkg-plist Wed May 7 12:41:29 2014 (r353151)
+++ head/net-mgmt/nagios4/pkg-plist Wed May 7 12:56:30 2014 (r353152)
@@ -1,22 +1,18 @@
- at exec mkdir -p %D/%%NAGIOSWWWDIR%%/ssi
- at exec mkdir -p %%NAGIOSDIR%%/archives
- at exec mkdir -p %%NAGIOSDIR%%/checkresults
- at exec mkdir -p %%NAGIOSDIR%%/rw
- at exec chmod 775 %%NAGIOSDIR%% %%NAGIOSDIR%%/archives %%NAGIOSDIR%%/checkresults %%NAGIOSDIR%%/rw
- at exec chown %%NAGIOSUSER%%:%%NAGIOSGROUP%% %%NAGIOSDIR%% %%NAGIOSDIR%%/archives %%NAGIOSDIR%%/checkresults
- at exec chown %%NAGIOSUSER%%:%%WWWGRP%% %%NAGIOSDIR%%/rw
+ at exec install -d %D/%%NAGIOSWWWDIR%%/ssi
+ at exec install -d -m 775 -o %%NAGIOSUSER%% -g %%NAGIOSGROUP%% %%NAGIOSDIR%% %%NAGIOSDIR%%/archives %%NAGIOSDIR%%/checkresults
+ at exec install -d -m 775 -o %%NAGIOSUSER%% -g %%WWWGRP%% %%NAGIOSDIR%%/rw
bin/nagios
bin/nagiostats
-etc/nagios/cgi.cfg-sample
-etc/nagios/nagios.cfg-sample
-etc/nagios/objects/commands.cfg-sample
-etc/nagios/objects/contacts.cfg-sample
-etc/nagios/objects/localhost.cfg-sample
-etc/nagios/objects/printer.cfg-sample
-etc/nagios/objects/switch.cfg-sample
-etc/nagios/objects/templates.cfg-sample
-etc/nagios/objects/timeperiods.cfg-sample
-etc/nagios/resource.cfg-sample
+%%ETCDIR%%/cgi.cfg-sample
+%%ETCDIR%%/nagios.cfg-sample
+%%ETCDIR%%/objects/commands.cfg-sample
+%%ETCDIR%%/objects/contacts.cfg-sample
+%%ETCDIR%%/objects/localhost.cfg-sample
+%%ETCDIR%%/objects/printer.cfg-sample
+%%ETCDIR%%/objects/switch.cfg-sample
+%%ETCDIR%%/objects/templates.cfg-sample
+%%ETCDIR%%/objects/timeperiods.cfg-sample
+%%ETCDIR%%/resource.cfg-sample
%%NAGIOSWWWDIR%%/cgi-bin/archivejson.cgi
%%NAGIOSWWWDIR%%/cgi-bin/avail.cgi
%%NAGIOSWWWDIR%%/cgi-bin/cmd.cgi
@@ -364,7 +360,10 @@ etc/nagios/resource.cfg-sample
%%NAGIOSWWWDIR%%/jsonquery.html
%%NAGIOSWWWDIR%%/main.php
%%NAGIOSWWWDIR%%/robots.txt
+%%NAGIOSWWWDIR%%/rss-corebanner.php
+%%NAGIOSWWWDIR%%/rss-corefeed.html
%%NAGIOSWWWDIR%%/rss-corefeed.php
+%%NAGIOSWWWDIR%%/rss-newsfeed.html
%%NAGIOSWWWDIR%%/rss-newsfeed.php
%%NAGIOSWWWDIR%%/side.php
%%NAGIOSWWWDIR%%/stylesheets/avail.css
@@ -385,9 +384,9 @@ etc/nagios/resource.cfg-sample
%%NAGIOSWWWDIR%%/stylesheets/summary.css
%%NAGIOSWWWDIR%%/stylesheets/tac.css
%%NAGIOSWWWDIR%%/stylesheets/trends.css
+ at dirrmtry %%ETCDIR%%/objects
+ at dirrmtry %%ETCDIR%%
@dirrmtry libexec/nagios
- at dirrmtry etc/nagios/objects
- at dirrmtry etc/nagios
@dirrm %%NAGIOSWWWDIR%%/cgi-bin
@dirrm %%NAGIOSWWWDIR%%/contexthelp
@dirrm %%NAGIOSWWWDIR%%/docs/images
More information about the svn-ports-head
mailing list