aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils/munin-node
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils/munin-node')
-rw-r--r--sysutils/munin-node/Makefile14
-rw-r--r--sysutils/munin-node/files/pkg-message.in7
-rw-r--r--sysutils/munin-node/pkg-deinstall36
-rw-r--r--sysutils/munin-node/pkg-install9
4 files changed, 22 insertions, 44 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile
index 03071c8e2aff..d881dfceb8fe 100644
--- a/sysutils/munin-node/Makefile
+++ b/sysutils/munin-node/Makefile
@@ -3,7 +3,6 @@
PORTNAME= munin
PORTVERSION= ${MUNIN_VERSION}
-PORTREVISION= 2
CATEGORIES= sysutils perl5
MASTER_SITES= ${MUNIN_SITES}
PKGNAMESUFFIX= -node
@@ -15,13 +14,11 @@ BUILD_DEPENDS= p5-Module-Build>=0:${PORTSDIR}/devel/p5-Module-Build \
p5-DateTime-HiRes>=0:${PORTSDIR}/devel/p5-DateTime-HiRes \
munin-common>=0:${PORTSDIR}/sysutils/munin-common \
p5-Net-Server>=0:${PORTSDIR}/net/p5-Net-Server \
- p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP \
bash:${PORTSDIR}/shells/bash
RUN_DEPENDS= p5-Cache-Cache>=0:${PORTSDIR}/devel/p5-Cache-Cache \
p5-DateTime-HiRes>=0:${PORTSDIR}/devel/p5-DateTime-HiRes \
munin-common>=0:${PORTSDIR}/sysutils/munin-common \
p5-Net-Server>=0:${PORTSDIR}/net/p5-Net-Server \
- p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP \
p5-Net-CIDR>=0:${PORTSDIR}/net-mgmt/p5-Net-CIDR \
bash:${PORTSDIR}/shells/bash
@@ -39,6 +36,17 @@ SHEBANG_FILES= node/sbin/munin-node
ALL_TARGET= build-node build-plugins
INSTALL_TARGET= install-node-prime install-plugins-prime
+OPTIONS_DEFINE= SNMP
+OPTIONS_DEFAULT= SNMP
+SNMP_DESC= Include support for SNMP plugins
+
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MSNMP}
+BUILD_DEPENDS+= p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP
+RUN_DEPENDS+= p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP
+.endif
+
MAN1= munin-node-configure.1 \
munin-node.1 \
munin-run.1 \
diff --git a/sysutils/munin-node/files/pkg-message.in b/sysutils/munin-node/files/pkg-message.in
index 3b0d85fa8955..5b92e905035b 100644
--- a/sysutils/munin-node/files/pkg-message.in
+++ b/sysutils/munin-node/files/pkg-message.in
@@ -17,3 +17,10 @@ present, the client will be started now. Otherwise, edit
%%PREFIX%%/etc/rc.d/munin-node start
********************************************************************
+
+For a list of plugins that will probably work run
+%%PREFIX%%/sbin/munin-node-configure --suggest
+
+If this is a fresh install run
+%%PREFIX%%/sbin/munin-node-configure --shell | sh -x
+to install the plugins automatically
diff --git a/sysutils/munin-node/pkg-deinstall b/sysutils/munin-node/pkg-deinstall
index adfdda136117..66cf3949ad78 100644
--- a/sysutils/munin-node/pkg-deinstall
+++ b/sysutils/munin-node/pkg-deinstall
@@ -1,34 +1,5 @@
#! /bin/sh
-ask() {
- local question default answer
-
- question=$1
- default=$2
- if [ -z "${PACKAGE_BUILDING}" -a -z "${BATCH}" ]; then
- read -p "${question} [${default}]? " answer
- fi
- if [ x${answer} = x ]; then
- answer=${default}
- fi
- echo ${answer}
-}
-
-yesno() {
- local dflt question answer
-
- question=$1
- dflt=$2
- while :; do
- answer=$(ask "${question}" "${dflt}")
- case "${answer}" in
- [Yy]*) return 0;;
- [Nn]*) return 1;;
- esac
- echo "Please answer yes or no."
- done
-}
-
stop_process() {
STARTSTOP=${PKG_PREFIX}/etc/rc.d/munin-node
@@ -51,10 +22,9 @@ newsyslog() {
exit 0
elif [ "$ENTRY" = "$DEFAULT" ]; then
delnewsyslog
- elif yesno "You have changed the default munin-node entry in \"/etc/newsyslog.conf\".
-Do you want me to delete it?" y; then
- delnewsyslog
- echo "Done."
+ else
+ echo "You have changed the default munin-node entry in \"/etc/newsyslog.conf\"".
+ echo "If you deinstall munin-node permanently, you have to manually remove it"
fi
}
diff --git a/sysutils/munin-node/pkg-install b/sysutils/munin-node/pkg-install
index a793c928d3a8..ffbd0806878f 100644
--- a/sysutils/munin-node/pkg-install
+++ b/sysutils/munin-node/pkg-install
@@ -37,9 +37,6 @@ init_plugins() {
if [ -n "$prevver" ]; then
echo -n "Initializing new plugins.."
${PKG_PREFIX}/sbin/munin-node-configure --shell --newer "${prevver%-*}" | sh -x
- else
- echo -n "Initializing plugins.."
- ${PKG_PREFIX}/sbin/munin-node-configure --shell | sh -x
fi
echo "done."
}
@@ -65,7 +62,6 @@ EOT
}
newsyslog() {
- if yesno "Would you like me to set up log rotation" y; then
if grep -q /var/log/munin/munin-node.log /etc/newsyslog.conf; then
:
else
@@ -73,9 +69,6 @@ newsyslog() {
/var/log/munin/munin-node.log 644 7 * @T00 Z /var/run/munin/munin-node.pid
EOT
fi
- else
- echo "/var/log/munin-node.log will grow without bounds."
- fi
}
@@ -90,5 +83,5 @@ case $2 in
${PKG_PREFIX}/etc/rc.d/munin-node start
newsyslog
fi
- ;;
+ ;;
esac