mirror of
https://git.freebsd.org/ports.git
synced 2025-06-10 15:20:32 -04:00
24 lines
509 B
Bash
24 lines
509 B
Bash
#!/bin/sh
|
|
|
|
# PROVIDE: semaphore
|
|
# REQUIRE: mysql
|
|
# KEYWORD: shutdown
|
|
|
|
. /etc/rc.subr
|
|
|
|
name=semaphore
|
|
rcvar=semaphore_enable
|
|
|
|
load_rc_config ${name}
|
|
|
|
: ${semaphore_enable:="NO"}
|
|
: ${semaphore_config="%%PREFIX%%/etc/semaphore/semaphore_config.json"}
|
|
|
|
export PATH=${PATH}:%%PREFIX%%/bin
|
|
|
|
pidfile="/var/run/${name}.pid"
|
|
procname="%%PREFIX%%/bin/semaphore"
|
|
command="/usr/sbin/daemon"
|
|
command_args="-f -c -p ${pidfile} /usr/bin/env ${semaphore_env} ${procname} -config \"${semaphore_config}\""
|
|
|
|
run_rc_command "$1"
|