mirror of
https://github.com/Motion-Project/motion.git
synced 2025-12-23 23:18:21 -05:00
27 lines
482 B
Bash
27 lines
482 B
Bash
#!/bin/sh
|
|
#
|
|
# motion.sh for rc.d usage 2006 Angel Carpintero
|
|
#
|
|
# Add the following line in /etc/rc.conf to enable @PACKAGE_NAME@ at startup
|
|
#
|
|
# motion_enable="YES"
|
|
#
|
|
|
|
# PROVIDE: @PACKAGE_NAME@
|
|
# REQUIRE: DAEMON
|
|
# KEYWORD: shutdown
|
|
|
|
. /etc/rc.subr
|
|
|
|
motion_enable="${motion_enable-NO}"
|
|
|
|
name="@PACKAGE_NAME@"
|
|
rcvar=`set_rcvar`
|
|
|
|
command="@BIN_PATH@/${name}"
|
|
pidfile="/var/run/${name}.pid"
|
|
required_files="/usr/local/etc/motion/${name}.conf"
|
|
|
|
load_rc_config $name
|
|
run_rc_command "$1"
|