6c27ac50f1
- Some style changes to match Porter's Handbook Suggested by: dougb
35 lines
584 B
Bash
35 lines
584 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD: /tmp/pcvs/ports/databases/pgcluster/files/Attic/pglb.in,v 1.2 2007-07-26 16:05:04 rafan Exp $
|
|
#
|
|
# PROVIDE: pglb
|
|
# REQUIRE: DAEMON
|
|
#
|
|
# Add the following line to /etc/rc.conf to enable pglb:
|
|
#
|
|
# pglb_enable="YES"
|
|
#
|
|
|
|
. %%RC_SUBR%%
|
|
|
|
name="pglb"
|
|
rcvar=`set_rcvar`
|
|
|
|
command=%%PREFIX%%/bin/${name}
|
|
|
|
load_rc_config $name
|
|
|
|
: ${pglb_enable="NO"}
|
|
: ${pglb_data="%%PREFIX%%/pgsql/data"}
|
|
|
|
pglb_user=pgsql
|
|
pglb_flags="${pglb_flags} -D ${pglb_data}"
|
|
|
|
stop_cmd="pglb_stop"
|
|
|
|
pglb_stop()
|
|
{
|
|
su -m ${pglb_user} -c "exec ${command} -D ${pglb_data} stop"
|
|
}
|
|
|
|
run_rc_command "$1"
|