aboutsummaryrefslogtreecommitdiff
path: root/sysutils/munin-node
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils/munin-node')
-rw-r--r--sysutils/munin-node/Makefile1
-rw-r--r--sysutils/munin-node/files/pkg-message.in16
-rw-r--r--sysutils/munin-node/pkg-install18
-rw-r--r--sysutils/munin-node/pkg-plist2
4 files changed, 36 insertions, 1 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile
index 1d87768dab69..a9afd2465599 100644
--- a/sysutils/munin-node/Makefile
+++ b/sysutils/munin-node/Makefile
@@ -3,6 +3,7 @@
PORTNAME= munin
PORTVERSION= ${MUNIN_VERSION}
+PORTREVISION= 1
CATEGORIES= sysutils perl5
MASTER_SITES= ${MUNIN_SITES}
PKGNAMESUFFIX= -node
diff --git a/sysutils/munin-node/files/pkg-message.in b/sysutils/munin-node/files/pkg-message.in
index 5b92e905035b..b652c5a2ad97 100644
--- a/sysutils/munin-node/files/pkg-message.in
+++ b/sysutils/munin-node/files/pkg-message.in
@@ -24,3 +24,19 @@ For a list of plugins that will probably work run
If this is a fresh install run
%%PREFIX%%/sbin/munin-node-configure --shell | sh -x
to install the plugins automatically
+
+********************************************************************
+The munin-node newsyslog.conf(5) filename has been changed:
+ OLD: ${PREFIX}/etc/newsyslog.conf.d/munin-node
+ NEW: ${PREFIX}/etc/newsyslog.conf.d/munin-node.conf
+
+Any file found at the old location has been automatically moved to
+the new location. This was done to ensure log rotation continued to
+work after change r340318 made to FreeBSD base, where the default
+newsyslog configuration now only includes filenames that end with
+'.conf' and do not begin with '.'.
+
+If you use provisioning/configuration management tools to create or
+edit this file, you will need to change their configuration to use
+the new filename.
+********************************************************************
diff --git a/sysutils/munin-node/pkg-install b/sysutils/munin-node/pkg-install
index dd48b19a7058..71212351548e 100644
--- a/sysutils/munin-node/pkg-install
+++ b/sysutils/munin-node/pkg-install
@@ -12,6 +12,23 @@ init_plugins() {
echo "done."
}
+move_newsyslog_conf() {
+ oldfile=${PKG_PREFIX}/etc/newsyslog.conf.d/munin-node
+ newfile=${PKG_PREFIX}/etc/newsyslog.conf.d/munin-node.conf
+ samplefile=${PKG_PREFIX}/etc/munin/munin-node.newsyslog
+ if [ -f ${oldfile} ]; then
+ echo "Configuration file found in old location: ${oldfile}"
+ if cmp -s ${samplefile} ${newfile} > /dev/null; then
+ echo "Configuration file in new location has not been modified from the default: ${newfile}"
+ echo " => Moving old configuration file to new location"
+ mv -f ${oldfile} ${newfile}
+ else
+ echo "Configuration file in new location has been modified from the default: ${newfile}"
+ echo " => Deleting old configuration file"
+ rm ${oldfile}
+ fi
+ fi
+}
########################################################################
@@ -20,5 +37,6 @@ case $2 in
if [ -z "${PACKAGE_BUILDING}" ]; then
init_plugins
fi
+ move_newsyslog_conf
;;
esac
diff --git a/sysutils/munin-node/pkg-plist b/sysutils/munin-node/pkg-plist
index 31b36fb16ef5..64476e1a466d 100644
--- a/sysutils/munin-node/pkg-plist
+++ b/sysutils/munin-node/pkg-plist
@@ -6,7 +6,7 @@ bin/munindoc
@comment BSD.local.dist but if not registered here, it will not exist in PREFIX
@comment when the package is installed.
@dir etc/newsyslog.conf.d
-@sample %%ETCDIR%%/munin-node.newsyslog etc/newsyslog.conf.d/munin-node
+@sample %%ETCDIR%%/munin-node.newsyslog etc/newsyslog.conf.d/munin-node.conf
%%SITE_PERL%%/Munin/Node/Config.pm
%%SITE_PERL%%/Munin/Node/Configure/Debug.pm
%%SITE_PERL%%/Munin/Node/Configure/History.pm