aboutsummaryrefslogtreecommitdiffstats
path: root/www/fcgiwrap
diff options
context:
space:
mode:
authorbapt <bapt@FreeBSD.org>2010-12-01 15:13:56 +0800
committerbapt <bapt@FreeBSD.org>2010-12-01 15:13:56 +0800
commitac669bd2ccc54080b0746cc7e23d3e7db8b2585f (patch)
tree2fcc3a1820d1d330c7137c053fb67b632a3e0ee5 /www/fcgiwrap
parent55b10d828583618e7e664fc58312a74226475424 (diff)
downloadfreebsd-ports-gnome-ac669bd2ccc54080b0746cc7e23d3e7db8b2585f.tar.gz
freebsd-ports-gnome-ac669bd2ccc54080b0746cc7e23d3e7db8b2585f.tar.zst
freebsd-ports-gnome-ac669bd2ccc54080b0746cc7e23d3e7db8b2585f.zip
- s/login/LOGIN/ in rc script
- cleaner way to handle pre_cmd - cleanup pid file left behind Reported by: dougb
Diffstat (limited to 'www/fcgiwrap')
-rw-r--r--www/fcgiwrap/files/fcgiwrap.in11
1 files changed, 4 insertions, 7 deletions
diff --git a/www/fcgiwrap/files/fcgiwrap.in b/www/fcgiwrap/files/fcgiwrap.in
index 82f4f451d1c4..39bc2084701d 100644
--- a/www/fcgiwrap/files/fcgiwrap.in
+++ b/www/fcgiwrap/files/fcgiwrap.in
@@ -5,7 +5,7 @@
# fcgiwrap startup script
#
# PROVIDE: fcgiwrap
-# REQUIRE: login
+# REQUIRE: LOGIN
# KEYWORD: shutdown
#
@@ -36,11 +36,7 @@ fcgiwrap_setfib() {
fcgiwrap_precmd() {
fcgiwrap_setfib
-
- test -d /var/run/fcgiwrap || mkdir -p /var/run/fcgiwrap
- if [ -n "${fcgiwrap_user}" ]; then
- chown -R ${fcgiwrap_user} /var/run/fcgiwrap
- fi
+ install -d -o $fcgiwrap_user -m 755 /var/run/fcgiwrap
}
fcgiwrap_cleansocket() {
@@ -50,7 +46,7 @@ fcgiwrap_cleansocket() {
test -S ${fcgiwrap_socket#unix:} && rm -f ${fcgiwrap_socket#unix:}
;;
esac
-
+ rm -f $pidfile
}
. /etc/rc.subr
@@ -68,6 +64,7 @@ load_rc_config $name
fcgiwrap_enable=${fcgiwrap_enable:-"NO"}
fcgiwrap_fib=${fcgiwrap_fib:-"NONE"}
+fcgiwrap_user=${fcgiwrap_user:-"root"}
fcgiwrap_socket=${fcgiwrap_socket:-"unix:/var/run/fcgiwrap/fcgiwrap.sock"}
command_args="-f -p ${pidfile} ${procname} -s ${fcgiwrap_socket}"