28 lines
611 B
Bash
28 lines
611 B
Bash
#!/bin/sh
|
|
#
|
|
# $OpenBSD: aircontrol.rc,v 1.6 2011/07/01 10:54:53 sthen Exp $
|
|
|
|
daemon="${TRUEPREFIX}/bin/catalina.sh"
|
|
daemon_flags="-Xmx768M -server"
|
|
daemon_user="_aircontrol"
|
|
|
|
. /etc/rc.d/rc.subr
|
|
|
|
pexp="$(${LOCALBASE}/bin/javaPathHelper -h aircontrol).*-Dcatalina.base=/var/aircontrol"
|
|
|
|
rc_reload=NO
|
|
|
|
rc_start() {
|
|
${rcexec} \
|
|
"CATALINA_OPTS=\"${daemon_flags}\" \
|
|
JAVA_HOME=\"$(${LOCALBASE}/bin/javaPathHelper -h aircontrol)\" ${daemon} start"
|
|
}
|
|
|
|
rc_stop() {
|
|
CATALINA_OPTS="${daemon_flags}" \
|
|
JAVA_HOME="$(${LOCALBASE}/bin/javaPathHelper -h aircontrol)" \
|
|
${daemon} stop
|
|
}
|
|
|
|
rc_cmd $1
|