summaryrefslogtreecommitdiff
path: root/sysutils/mbmon/files/mbmon.in
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils/mbmon/files/mbmon.in')
-rw-r--r--sysutils/mbmon/files/mbmon.in32
1 files changed, 32 insertions, 0 deletions
diff --git a/sysutils/mbmon/files/mbmon.in b/sysutils/mbmon/files/mbmon.in
new file mode 100644
index 000000000000..a06f60157ae4
--- /dev/null
+++ b/sysutils/mbmon/files/mbmon.in
@@ -0,0 +1,32 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: mbmon
+# REQUIRE: LOGIN
+# BEFORE: securelevel
+# KEYWORD: shutdown
+
+# Add the following lines to /etc/rc.conf to enable the mbmon daemon:
+#
+# mbmon_enable="YES"
+# mbmon_flags="<set as needed>"
+#
+# See mbmon(1) for mbmon_flags
+# Set mbmon_port to the TCP port to listen to, default is 12999
+
+. /etc/rc.subr
+
+name="mbmon"
+rcvar=mbmon_enable
+
+# read configuration and set defaults
+load_rc_config "$name"
+: ${mbmon_enable="NO"}
+: ${mbmon_port="12999"}
+
+command="%%PREFIX%%/bin/${name}"
+command_args="-P ${mbmon_port}"
+
+run_rc_command "$1"