83283fa6fe
- Change rc.d script to allow to run with negative priority. [1] PR: 108465 [1] Submitted by: Anton Yuzhaninov <citrin___rambler-co.ru> [1]
33 lines
650 B
Bash
33 lines
650 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
# PROVIDE: memcached
|
|
# REQUIRE: DAEMON
|
|
#
|
|
# Add the following lines to /etc/rc.conf to run memcached:
|
|
#
|
|
# memcached_enable (bool): Set it to "YES" to enable memcached.
|
|
# Default is "NO".
|
|
# memcached_flags (flags): Set extra flags here. More options in memcached(1)
|
|
# Default is empty "".
|
|
# memcached_user (user): Set user to run memcached.
|
|
# Default is "nobody".
|
|
#
|
|
|
|
. %%RC_SUBR%%
|
|
|
|
name="memcached"
|
|
rcvar=${name}_enable
|
|
|
|
load_rc_config ${name}
|
|
|
|
: ${memcached_enable="NO"}
|
|
: ${memcached_user="nobody"}
|
|
|
|
command=%%PREFIX%%/bin/memcached
|
|
command_args="-d -u ${memcached_user}"
|
|
|
|
unset memcached_user
|
|
|
|
run_rc_command "$1"
|