aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authormat <mat@FreeBSD.org>2014-12-11 15:59:03 +0800
committermat <mat@FreeBSD.org>2014-12-11 15:59:03 +0800
commite91b9dbf322de0502014266988e059e5d8619aef (patch)
treee5698adfca71fa197dbd6d847cfaffb2ababbd02 /sysutils
parenta68f838160daf8659113dcb12c6e50386586412e (diff)
downloadfreebsd-ports-gnome-e91b9dbf322de0502014266988e059e5d8619aef.tar.gz
freebsd-ports-gnome-e91b9dbf322de0502014266988e059e5d8619aef.tar.zst
freebsd-ports-gnome-e91b9dbf322de0502014266988e059e5d8619aef.zip
Cleanup pkg-{,de}install, don't restart munin-node from here, pkg can do it itself.
Sponsored by: Absolight
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/munin-node/Makefile2
-rw-r--r--sysutils/munin-node/pkg-deinstall9
-rw-r--r--sysutils/munin-node/pkg-install50
3 files changed, 1 insertions, 60 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile
index 9ccf8ce619d0..de7bd6dce2f3 100644
--- a/sysutils/munin-node/Makefile
+++ b/sysutils/munin-node/Makefile
@@ -3,7 +3,7 @@
PORTNAME= munin
PORTVERSION= ${MUNIN_VERSION}
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= sysutils perl5
MASTER_SITES= ${MUNIN_SITES}
PKGNAMESUFFIX= -node
diff --git a/sysutils/munin-node/pkg-deinstall b/sysutils/munin-node/pkg-deinstall
index 66cf3949ad78..8b7b8d9f6e7d 100644
--- a/sysutils/munin-node/pkg-deinstall
+++ b/sysutils/munin-node/pkg-deinstall
@@ -1,13 +1,5 @@
#! /bin/sh
-stop_process() {
- STARTSTOP=${PKG_PREFIX}/etc/rc.d/munin-node
-
- if [ -x $STARTSTOP ]; then
- $STARTSTOP stop
- fi
-}
-
delnewsyslog() {
tmp="/etc/#munin-node$$"
sed -e '/^\/var\/log\/munin\/munin-node.log[ ]/d' /etc/newsyslog.conf >${tmp}
@@ -32,7 +24,6 @@ newsyslog() {
case $2 in
DEINSTALL)
if [ -z "${PACKAGE_BUILDING}" ]; then
- stop_process
newsyslog
fi
;;
diff --git a/sysutils/munin-node/pkg-install b/sysutils/munin-node/pkg-install
index ffbd0806878f..a9d45dad0841 100644
--- a/sysutils/munin-node/pkg-install
+++ b/sysutils/munin-node/pkg-install
@@ -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
-}
-
init_plugins() {
if [ -f /tmp/.munin-node.version ]; then
prevver=$(cat /tmp/.munin-node.version)
@@ -41,26 +12,6 @@ init_plugins() {
echo "done."
}
-create_crontab_entries() {
- local sched prog
- sched=$1
- prog=$2
-
- if grep -q "^[^#]*$prog" /etc/crontab; then
- echo "It looks like your crontab is already set up, so I'll use that."
- else
- echo "It looks like your perl suffers from unsafe signals."
- if yesno "Would you like me to set up your root crontab to restart munin-node" y; then
- cat <<EOT >>/etc/crontab
-$sched root $prog
-EOT
- else
- echo "You may suffer from munin-node crashing after log rotation."
- echo "If you still want to restart munin-node, use $prog."
- fi
- fi
-}
-
newsyslog() {
if grep -q /var/log/munin/munin-node.log /etc/newsyslog.conf; then
:
@@ -80,7 +31,6 @@ case $2 in
POST-INSTALL)
if [ -z "${PACKAGE_BUILDING}" ]; then
init_plugins
- ${PKG_PREFIX}/etc/rc.d/munin-node start
newsyslog
fi
;;