aboutsummaryrefslogtreecommitdiff
path: root/sysutils/monit
diff options
context:
space:
mode:
authorKirill Ponomarev <krion@FreeBSD.org>2005-02-18 19:14:12 +0000
committerKirill Ponomarev <krion@FreeBSD.org>2005-02-18 19:14:12 +0000
commitaa06cae11d5806a8976e14813fd79f11e021db40 (patch)
treefe196721e0ded0a35954353d3ccda21ffe93d506 /sysutils/monit
parent1860d1b25a20007ff70521b319e7df6d5cb71031 (diff)
downloadports-aa06cae11d5806a8976e14813fd79f11e021db40.tar.gz
ports-aa06cae11d5806a8976e14813fd79f11e021db40.zip
Notes
Diffstat (limited to 'sysutils/monit')
-rw-r--r--sysutils/monit/Makefile76
-rw-r--r--sysutils/monit/distinfo2
-rw-r--r--sysutils/monit/files/monit.sh47
-rw-r--r--sysutils/monit/pkg-descr24
-rw-r--r--sysutils/monit/pkg-message5
5 files changed, 154 insertions, 0 deletions
diff --git a/sysutils/monit/Makefile b/sysutils/monit/Makefile
new file mode 100644
index 000000000000..2a62976830ee
--- /dev/null
+++ b/sysutils/monit/Makefile
@@ -0,0 +1,76 @@
+# New ports collection makefile for: monit
+# Date created: 4 Januar 2005
+# Whom: Martin Pala <martinp@tildeslash.com>
+#
+# $FreeBSD$
+#
+
+PORTNAME= monit
+PORTVERSION= 4.4
+CATEGORIES= sysutils
+MASTER_SITES= http://www.tildeslash.com/monit/dist/
+
+MAINTAINER= martinp@tildeslash.com
+COMMENT= Unix system management and monitoring tool
+
+MAN1= monit.1
+
+GNU_CONFIGURE= yes
+USE_GMAKE= yes
+USE_BISON= yes
+USE_RC_SUBR= yes
+
+CONFIGURE_ENV= CC="${CC}" CPPFLAGS="${CPPFLAGS}" \
+ CFLAGS="${CFLAGS}" \
+ LDFLAGS="${LDFLAGS}" CONFIG_SHELL="${SH}" \
+ LOCALBASE="${LOCALBASE}"
+
+OPTIONS= MONIT_SSL "Enable SSL support" on
+
+PLIST_FILES= bin/monit \
+ etc/monitrc.sample \
+ etc/rc.d/monit.sh \
+ share/doc/monit/CHANGES.txt \
+ share/doc/monit/CONTRIBUTORS \
+ share/doc/monit/FAQ.txt \
+ share/doc/monit/LICENSE \
+ share/doc/monit/README \
+ share/doc/monit/README.SSL \
+ share/doc/monit/STATUS \
+ share/doc/monit/examples.html \
+ share/doc/monit/monit.html
+PLIST_DIRS= share/doc/monit
+
+.include <bsd.port.pre.mk>
+
+pre-install:
+ @${SED} -e 's|%%PREFIX%%|${PREFIX}|g' \
+ -e 's|%%RC_SUBR%%|${RC_SUBR}|g' \
+ ${FILESDIR}/monit.sh > ${WRKDIR}/monit.sh
+
+post-install:
+ @${INSTALL_SCRIPT} -m 755 ${WRKDIR}/monit.sh ${PREFIX}/etc/rc.d/monit.sh
+ @${INSTALL_SCRIPT} -m 600 ${WRKDIR}/${DISTNAME}/monitrc ${PREFIX}/etc/monitrc.sample
+ ${MKDIR} ${DOCSDIR}
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/CHANGES.txt ${PREFIX}/share/doc/monit/CHANGES.txt
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/CONTRIBUTORS ${PREFIX}/share/doc/monit/CONTRIBUTORS
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/FAQ.txt ${PREFIX}/share/doc/monit/FAQ.txt
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/LICENSE ${PREFIX}/share/doc/monit/LICENSE
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/README ${PREFIX}/share/doc/monit/README
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/README.SSL ${PREFIX}/share/doc/monit/README.SSL
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/STATUS ${PREFIX}/share/doc/monit/STATUS
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/doc/examples.html ${PREFIX}/share/doc/monit/examples.html
+ @${INSTALL_SCRIPT} -m 644 ${WRKDIR}/${DISTNAME}/doc/monit.html ${PREFIX}/share/doc/monit/monit.html
+ @${CAT} ${PKGMESSAGE}
+ @${ECHO_MSG} " ${PREFIX}/etc/monitrc.sample"
+ @${ECHO_MSG} " ${PREFIX}/share/doc/monit/examples.html"
+
+.if defined(WITH_MONIT_SSL)
+.include "${PORTSDIR}/Mk/bsd.openssl.mk"
+CONFIGURE_ARGS+= --enable-ssl \
+ --with-openssl="${OPENSSLBASE}"
+.else
+CONFIGURE_ARGS+= --without-ssl
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/sysutils/monit/distinfo b/sysutils/monit/distinfo
new file mode 100644
index 000000000000..67984bcd8314
--- /dev/null
+++ b/sysutils/monit/distinfo
@@ -0,0 +1,2 @@
+MD5 (monit-4.4.tar.gz) = 671e1882ae342118a2138a3468589967
+SIZE (monit-4.4.tar.gz) = 458083
diff --git a/sysutils/monit/files/monit.sh b/sysutils/monit/files/monit.sh
new file mode 100644
index 000000000000..a7739da45555
--- /dev/null
+++ b/sysutils/monit/files/monit.sh
@@ -0,0 +1,47 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: monit
+# REQUIRE: NETWORKING SERVERS
+# BEFORE: DAEMON
+# KEYWORD: shutdown
+
+#
+# Add the following lines to /etc/rc.conf to enable monit:
+# monit_enable (bool): Set to "NO" by default.
+# Set it to "YES" to enable monit
+#
+. %%RC_SUBR%%
+
+name="monit"
+rcvar=`set_rcvar`
+
+restart_precmd="monit_checkconfig"
+reload_precmd="monit_checkconfig"
+stop_cmd="monit_stop"
+
+default_config=%%PREFIX%%/etc/monitrc
+required_files=${default_config}
+command="%%PREFIX%%/bin/monit"
+command_args="-c ${default_config}"
+pidfile="/var/run/monit.pid"
+
+[ -z "$monit_enable" ] && monit_enable="NO"
+
+load_rc_config $name
+
+monit_checkconfig()
+{
+ echo "Performing sanity check on monit configuration:"
+ ${command} ${command_args} -t
+}
+
+monit_stop() {
+ ${command} ${command_args} quit
+ run_rc_command poll
+}
+
+extra_commands="reload"
+run_rc_command "$1"
diff --git a/sysutils/monit/pkg-descr b/sysutils/monit/pkg-descr
new file mode 100644
index 000000000000..93aba19d7835
--- /dev/null
+++ b/sysutils/monit/pkg-descr
@@ -0,0 +1,24 @@
+Monit is a utility for managing and monitoring processes,
+files, directories, devices and network services on a Unix system.
+Monit conducts automatic maintenance and repair and can execute
+meaningful causal actions in error situations.
+
+monit supports:
+ * Daemon mode - poll services at a specified interval
+ * Group and manage groups of services, service dependencies
+ * Logging - syslog or own logfile
+ * Alert, start, stop and restart of services based on it's characteristics
+ * MD5 and SHA1 checksums
+ * Runtime Unix socket and TCP/IP port checking (tcp and udp)
+ * Process status, timeout, memory and cpu usage, etc.
+ * Device usage monitoring (inodes and space)
+ * File monitoring (timestamp, checksum, permission, owner, etc.)
+ * Directory monitoring (timestamp, permission, owner, etc.)
+ * Remote network services monitoring (ping, response time, protocol, etc.)
+ * System load average monitoring
+ * Flexible and customizable email alert messages and notifications
+ * Protocol verification such as HTTP, FTP, SMTP, POP, IMAP, NNTP, etc.
+ * A HTTP interface with XML output option
+ and many more features :)
+
+WWW: http://www.tildeslash.com/monit/
diff --git a/sysutils/monit/pkg-message b/sysutils/monit/pkg-message
new file mode 100644
index 000000000000..ef86d0296ac1
--- /dev/null
+++ b/sysutils/monit/pkg-message
@@ -0,0 +1,5 @@
+===> USAGE:
+ To enable monit you need to add monit_enable="YES" to rc.conf file.
+ Before running monit you have to configure monitrc file. There is
+ example configuration file monitrc.sample, you can find many
+ samples for particular services in examples.html: