diff options
author | Valery Kartel <valery.kartel@gmail.com> | 2017-02-16 03:43:10 +0200 |
---|---|---|
committer | Leonardo Arena <rnalrd@alpinelinux.org> | 2017-06-06 13:54:57 +0000 |
commit | 3fcde78eff6ea7d17dabe7fee352d39147b8d602 (patch) | |
tree | 7a0e4f080c37af60a887c226585779dada9b6b23 /main/spawn-fcgi/spawn-fcgi.initd | |
parent | b7a326232d701d67e71ec1b4d4eb9e4b89b9507e (diff) | |
download | aports-3fcde78eff6ea7d17dabe7fee352d39147b8d602.tar.bz2 aports-3fcde78eff6ea7d17dabe7fee352d39147b8d602.tar.xz |
main/spawn-fcgi: fix dealing with unix sockets
fix collision when both socket and tcp_port are set up
cleanups in APKBUILD and confd
Diffstat (limited to 'main/spawn-fcgi/spawn-fcgi.initd')
-rw-r--r-- | main/spawn-fcgi/spawn-fcgi.initd | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/main/spawn-fcgi/spawn-fcgi.initd b/main/spawn-fcgi/spawn-fcgi.initd index b33952939c..4571a15d28 100644 --- a/main/spawn-fcgi/spawn-fcgi.initd +++ b/main/spawn-fcgi/spawn-fcgi.initd @@ -1,7 +1,4 @@ #!/sbin/openrc-run -# Copyright 1999-2014 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/files/spawn-fcgi.initd-r2,v 1.1 2014/05/12 06:57:31 jlec Exp $ PROGNAME=${SVCNAME#*.} SPAWNFCGI=/usr/bin/spawn-fcgi @@ -28,13 +25,6 @@ start() { return 1 fi - if [ ! -z "${FCGI_SOCKET}" ] && [ ! -z "${FCGI_PORT}" ]; then - eerror "Only one of the two may be defined:" - eerror " FCGI_SOCKET=${FCGI_SOCKET}" - eerror " FCGI_PORT=${FCGI_PORT}" - return 1 - fi - if [ -z "${FCGI_PROGRAM}" ]; then eerror "You need to specify which \$FCGI_PROGRAM" eerror "you want to start." @@ -49,10 +39,19 @@ start() { return 1 fi + if [ -z "${FCGI_PORT}" ]; then + FCGI_PORT=1234 + fi + if [ -z "${FCGI_ADDRESS}" ]; then FCGI_ADDRESS=127.0.0.1 fi + if [ ! -z "${FCGI_SOCKET}" ]; then + unset FCGI_PORT + unset FCGI_ADDRESS + fi + if [ -z "${FCGI_CHILDREN}" ]; then FCGI_CHILDREN=1 fi |