Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 24 Apr 2016 16:58:58 +0000 (UTC)
From:      Lars Engels <lme@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r413950 - in head: . net-mgmt/icinga2 net-mgmt/icinga2/files
Message-ID:  <201604241658.u3OGwwL8084058@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: lme
Date: Sun Apr 24 16:58:58 2016
New Revision: 413950
URL: https://svnweb.freebsd.org/changeset/ports/413950

Log:
  - Update to 2.4.7
  - Introduce new rc.conf variable "icinga2_mkvar" defaulting to "NO". The
    variable controls the creation and chown'ing of missing files and
    directories in /var. [1]
  - Add an UPDATING entry for this
  
  PR:		206022 [1]
  Submitted by:	Oliver Hartmann <ohartman@zedat.fu-berlin.de>
  Sponsored by:	Essen Linuxhotel Hackathon 2016

Modified:
  head/UPDATING
  head/net-mgmt/icinga2/Makefile
  head/net-mgmt/icinga2/distinfo
  head/net-mgmt/icinga2/files/icinga2.in

Modified: head/UPDATING
==============================================================================
--- head/UPDATING	Sun Apr 24 16:51:36 2016	(r413949)
+++ head/UPDATING	Sun Apr 24 16:58:58 2016	(r413950)
@@ -5,6 +5,16 @@ they are unavoidable.
 You should get into the habit of checking this file for changes each time
 you update your ports collection, before attempting any port upgrades.
 
+20160414:
+  AFFECTS: Users of net-mgmt/icinga2
+  AUTHOR: lme@FreeBSD.org
+
+  The creation of Icinga2 directories and files in /var is now controlled 
+  by the /etc/rc.conf variable icinga2_mkvar.  Earlier ports always 
+  created the /var entries, but could slow startup significantly when /var 
+  was a normal disk rather than a RAM disk.  icinga2_mkvar defaults to 
+  "NO".
+
 20160415:
   AFFECTS: users of audio/chromaprint
   AUTHOR: jhale@FreeBSD.org
@@ -31,7 +41,6 @@ you update your ports collection, before
   ttrssd_local_db="NO"
   in your /etc/rc.conf .
 
-
 20160414:
   AFFECTS: Users of graphics/kipi-plugin-googledrive and graphics/kipi-plugin-picasaweb
   AUTHOR: kde@FreeBSD.org

Modified: head/net-mgmt/icinga2/Makefile
==============================================================================
--- head/net-mgmt/icinga2/Makefile	Sun Apr 24 16:51:36 2016	(r413949)
+++ head/net-mgmt/icinga2/Makefile	Sun Apr 24 16:58:58 2016	(r413950)
@@ -2,7 +2,7 @@
 
 PORTNAME=	icinga2
 DISTVERSIONPREFIX=	v
-DISTVERSION=	2.4.4
+DISTVERSION=	2.4.7
 CATEGORIES=	net-mgmt
 
 MAINTAINER=	lme@FreeBSD.org

Modified: head/net-mgmt/icinga2/distinfo
==============================================================================
--- head/net-mgmt/icinga2/distinfo	Sun Apr 24 16:51:36 2016	(r413949)
+++ head/net-mgmt/icinga2/distinfo	Sun Apr 24 16:58:58 2016	(r413950)
@@ -1,2 +1,2 @@
-SHA256 (icinga-icinga2-v2.4.4_GH0.tar.gz) = ce19ed52c447929f5f9dae11b75d080b76b7aa680ee930c59db4202a2218d6b5
-SIZE (icinga-icinga2-v2.4.4_GH0.tar.gz) = 1361983
+SHA256 (icinga-icinga2-v2.4.7_GH0.tar.gz) = db00c3bf1be5b18a477953f39df467039521d4f00826951d5c6de43cef96acd9
+SIZE (icinga-icinga2-v2.4.7_GH0.tar.gz) = 1763118

Modified: head/net-mgmt/icinga2/files/icinga2.in
==============================================================================
--- head/net-mgmt/icinga2/files/icinga2.in	Sun Apr 24 16:51:36 2016	(r413949)
+++ head/net-mgmt/icinga2/files/icinga2.in	Sun Apr 24 16:58:58 2016	(r413950)
@@ -12,6 +12,9 @@
 #                           Set it to "YES" to enable icinga2.
 # icinga2_flags (str):      Set to "" by default.
 # icinga2_configfile (str): Set to "%%PREFIX%%/etc/icinga2/icinga2.cfg" by default.
+# icinga2_mkvar (bool):     Set to "NO" by default.
+#                           Set it to "YES" to have the rc script create all
+#                           directories in /var (needed when /var is on a ramdisk)
 #
 
 . /etc/rc.subr
@@ -27,6 +30,7 @@ load_rc_config "${name}"
 
 : ${icinga2_enable:="NO"}
 : ${icinga2_configfile="%%PREFIX%%/etc/${name}/${name}.conf"}
+: ${icinga2_mkvar:="NO"}
 
 command="%%PREFIX%%/sbin/${name}"
 procname="/usr/local/lib/icinga2/sbin/icinga2"
@@ -79,26 +83,28 @@ reload_precmd() {
 }
 
 start_precmd() {
-  # Create necessary directories / change ownership
-  # 
-  # While this is also done through pkg-plist, /var might be on a ramdisk,
-  # so make sure all needed files and directories are created before starting
-  # Icinga.
-  for d in "${icinga2_logdir}" "${icinga2_logdir}/compat" \
-           "${icinga2_logdir}/compat/archives" "${icinga2_libdir}" \
-           "${icinga2_spooldir}" "${icinga2_spooldir}/tmp" \
-           "${icinga2_rundir}" "${icinga2_cachedir}"; do
-      if [ ! -d "${d}" ]; then
-        install -d -o ${icinga2_user} -g ${icinga2_group} "${d}"
-      else
-        chown ${icinga2_user}:${icinga2_group} "${d}"
-      fi
-  done
+  if checkyesno "icinga2_mkvar"; then
+    # Create necessary directories / change ownership
+    # 
+    # While this is also done through pkg-plist, /var might be on a ramdisk,
+    # so make sure all needed files and directories are created before starting
+    # Icinga.
+    for d in "${icinga2_logdir}" "${icinga2_logdir}/compat" \
+             "${icinga2_logdir}/compat/archives" "${icinga2_libdir}" \
+             "${icinga2_spooldir}" "${icinga2_spooldir}/tmp" \
+             "${icinga2_rundir}" "${icinga2_cachedir}"; do
+        if [ ! -d "${d}" ]; then
+          install -d -o ${icinga2_user} -g ${icinga2_group} "${d}"
+        else
+          chown ${icinga2_user}:${icinga2_group} "${d}"
+        fi
+    done
 
-  install -d -o ${icinga2_user} -g %%WWWGRP%% "${icinga2_rundir}/cmd" 
+    install -d -o ${icinga2_user} -g %%WWWGRP%% "${icinga2_rundir}/cmd" 
 
-  chown -R ${icinga2_user}:${icinga2_user} "${icinga2_libdir}"
-  chown -R ${icinga2_user}:${icinga2_user} "${icinga2_spooldir}"
+    chown -R ${icinga2_user}:${icinga2_user} "${icinga2_libdir}"
+    chown -R ${icinga2_user}:${icinga2_user} "${icinga2_spooldir}"
+  fi
 
   if ! icinga2_checkconfig; then
     return 1



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201604241658.u3OGwwL8084058>