summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorVlad Glagolev2021-07-31 01:28:47 +0000
committerVlad Glagolev2021-07-31 01:29:37 +0000
commitc3dabfb2fd8d784d182206a9f119f29af92a1348 (patch)
tree54882ea4c62f11d2be9d74d39ccfc8e34d0d3674 /net
parentfc2f7b39d76bb36e59440655da1b1f9580e3c09b (diff)
monit: => 5.28.1
Diffstat (limited to 'net')
-rwxr-xr-xnet/monit/BUILD1
-rwxr-xr-xnet/monit/DETAILS8
-rw-r--r--net/monit/HISTORY6
-rwxr-xr-xnet/monit/INSTALL4
-rwxr-xr-xnet/monit/PRE_INSTALL10
-rwxr-xr-xnet/monit/init.d/monit13
-rw-r--r--net/monit/init.d/monit.conf3
7 files changed, 32 insertions, 13 deletions
diff --git a/net/monit/BUILD b/net/monit/BUILD
index c0a255a442..b19941ec5c 100755
--- a/net/monit/BUILD
+++ b/net/monit/BUILD
@@ -1,5 +1,4 @@
OPTS="--bindir=$INSTALL_ROOT/sbin \
- --sysconfdir=$INSTALL_ROOT/etc/sysconfig \
$OPTS" &&
default_build
diff --git a/net/monit/DETAILS b/net/monit/DETAILS
index 8dcad65dc5..d841cab642 100755
--- a/net/monit/DETAILS
+++ b/net/monit/DETAILS
@@ -1,12 +1,12 @@
SPELL=monit
- VERSION=5.20.0
+ VERSION=5.28.1
SECURITY_PATCH=1
- PATCHLEVEL=1
- STAGED_INSTALL="off"
SOURCE="${SPELL}-${VERSION}.tar.gz"
SOURCE_URL[0]="http://mmonit.com/${SPELL}/dist/${SOURCE}"
- SOURCE_HASH=sha512:653cba9d63fad42acf8c27ee9c050d047fc78e0b7e8cdb0f3d0a533d5b5e01ccf1b82d443cb6518d286547087a021e37a59cbffedbb3daf49ff8f95e8c64b884
+ SOURCE_HASH=sha512:2683084aea88567309b4693247c27312e1cb4225175cb8643a1f980ed8fc8ecd549818e157e1bb6c0feafc306bc9217bbd2c0c501cb75ea2425b646955076e5a
SOURCE_DIRECTORY="${BUILD_DIRECTORY}/${SPELL}-${VERSION}"
+ DOC_DIRS=""
+ STAGED_INSTALL="off"
WEB_SITE="http://mmonit.com/monit/"
LICENSE[0]=GPL
KEYWORDS="net"
diff --git a/net/monit/HISTORY b/net/monit/HISTORY
index 88af74d260..fabe4b0c26 100644
--- a/net/monit/HISTORY
+++ b/net/monit/HISTORY
@@ -1,3 +1,9 @@
+2021-07-30 Vlad Glagolev <stealth@sourcemage.org>
+ * DETAILS: updated spell to 5.28.1; don't collect .pod files
+ * BUILD, INSTALL: updated monitrc path
+ * PRE_INSTALL: added, for monitrc migration
+ * init.d/monit.conf: added, monit args config
+
2020-08-24 Eric Sandall <sandalle@sourcemage.org>
* DETAILS: Disable castfs (STAGED_INSTALL), breaks install
diff --git a/net/monit/INSTALL b/net/monit/INSTALL
index e7468af834..514bdaf82c 100755
--- a/net/monit/INSTALL
+++ b/net/monit/INSTALL
@@ -1,8 +1,8 @@
default_install &&
install_config_file "$SOURCE_DIRECTORY/monitrc" \
- "$INSTALL_ROOT/etc/sysconfig/monitrc" &&
+ "$INSTALL_ROOT/etc/monitrc" &&
message "${MESSAGE_COLOR}Fixing monitrc permissions...${DEFAULT_COLOR}" &&
-chmod 600 "$INSTALL_ROOT/etc/sysconfig/monitrc"
+chmod 600 "$INSTALL_ROOT/etc/monitrc"
diff --git a/net/monit/PRE_INSTALL b/net/monit/PRE_INSTALL
new file mode 100755
index 0000000000..dc6eb522b6
--- /dev/null
+++ b/net/monit/PRE_INSTALL
@@ -0,0 +1,10 @@
+default_pre_install &&
+
+# migration from old monitrc location
+local new_monitrc="${INSTALL_ROOT}/etc/monitrc" &&
+local old_monitrc="${INSTALL_ROOT}/etc/sysconfig/monitrc" &&
+
+if [ ! -f "${new_monitrc}" ] && [ -f "${old_monitrc}" ] && grep -qv MONIT_ARGS= "${old_monitrc}"; then
+ message "${MESSAGE_COLOR}Migrating monitrc to ${INSTALL_ROOT}/etc${DEFAULT_COLOR}" &&
+ mv -v "${old_monitrc}" "${new_monitrc}"
+fi
diff --git a/net/monit/init.d/monit b/net/monit/init.d/monit
index aba1d2f59e..91fee552e3 100755
--- a/net/monit/init.d/monit
+++ b/net/monit/init.d/monit
@@ -1,16 +1,17 @@
#!/bin/bash
+. /etc/sysconfig/monit
+
PROGRAM=/sbin/monit
PIDFILE=/var/run/monit.pid
-ARGS="-c /etc/sysconfig/monitrc -p $PIDFILE"
+ARGS="$MONIT_ARGS -p $PIDFILE"
RUNLEVEL=2
NEEDS="+local_fs"
. /etc/init.d/smgl_init
-restart()
-{
- _stop &&
- sleep 1 &&
- _start
+restart() {
+ _stop &&
+ sleep 1 &&
+ _start
}
diff --git a/net/monit/init.d/monit.conf b/net/monit/init.d/monit.conf
new file mode 100644
index 0000000000..d676b5501a
--- /dev/null
+++ b/net/monit/init.d/monit.conf
@@ -0,0 +1,3 @@
+# For arguments and description see monit(1)
+
+MONIT_ARGS=""