Bug 94137 - databases/pgpool has no rc script. One is attached here with a makefile diff.
Summary: databases/pgpool has no rc script. One is attached here with a makefile diff.
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-03-06 12:00 UTC by Chris St Denis
Modified: 2006-04-14 19:41 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris St Denis 2006-03-06 12:00:18 UTC
pgpool is a deamon but has no rc script.

Fix: 

RC script in rc.subr format for pgpool listed below. I based this off the rc script for rsyncd.

Numbers added to filename to try and make it run after postgresql (if on localhost) but before any client programs that may refrence it.
 
022.pgpool.sh.in
---------------------------------------------------
#!/bin/sh
#
#
 
# PROVIDE: %%NAME%%
# REQUIRE: LOGIN
# BEFORE:  securelevel
# KEYWORD: FreeBSD shutdown
 
# Add the following line to /etc/rc.conf to enable `%%NAME%%':
#
#%%NAME%%_enable="YES"
#
 
. "%%RC_SUBR%%"
 
name="%%NAME%%"
rcvar=`set_rcvar`
 
command="%%PREFIX%%/bin/%%NAME%%"
stop_cmd="$command stop"
required_files="%%PREFIX%%/etc/$name.cfg"
 
# read configuration and set defaults
load_rc_config "$name"
: ${%%NAME%%_enable="NO"}
 
run_rc_command "$1"
 
----------------------------------------
and a diff of the Makefile
----------------------------------------

 --- Makefile.orig       Mon Mar  6 03:48:49 2006
+++ Makefile    Mon Mar  6 03:49:09 2006
@@ -15,6 +15,7 @@

 USE_GMAKE=     yes
 GNU_CONFIGURE= yes
+USE_RC_SUBR=    022.pgpool.sh

 PORTDOCS=      README AUTHORS COPYING ChangeLog INSTALL NEWS TODO README.euc_jp
How-To-Repeat: n/a
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2006-03-06 12:04:17 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback
Comment 2 Marcus Alves Grando freebsd_committer freebsd_triage 2006-04-14 19:41:12 UTC
State Changed
From-To: feedback->closed

Committed, with minor changes. Thanks!