summaryrefslogtreecommitdiff
path: root/filesystems/moosefs2-master/files/mfsmaster.in
diff options
context:
space:
mode:
Diffstat (limited to 'filesystems/moosefs2-master/files/mfsmaster.in')
-rw-r--r--filesystems/moosefs2-master/files/mfsmaster.in30
1 files changed, 30 insertions, 0 deletions
diff --git a/filesystems/moosefs2-master/files/mfsmaster.in b/filesystems/moosefs2-master/files/mfsmaster.in
new file mode 100644
index 000000000000..a551d441c5b1
--- /dev/null
+++ b/filesystems/moosefs2-master/files/mfsmaster.in
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+# PROVIDE: mfsmaster
+# REQUIRE: DAEMON
+# KEYWORD: nostart shutdown
+#
+# Add the following lines to /etc/rc.conf to enable mfsmaster:
+#
+# mfsmaster_enable="YES"
+#
+
+. /etc/rc.subr
+
+name=mfsmaster
+rcvar=mfsmaster_enable
+
+config_file=%%PREFIX%%/etc/mfs/${name}.cfg
+
+required_files=${config_file}
+
+command=%%PREFIX%%/sbin/${name}
+pid_file=%%MFS_WORKDIR%%/mfs/.${name}.lock
+command_args="-c $config_file"
+
+load_rc_config $name
+
+# set defaults
+: ${mfsmaster_enable="NO"}
+
+run_rc_command "$1"