diff options
author | Thilo Bangert <bangert@gentoo.org> | 2009-04-09 18:56:04 +0000 |
---|---|---|
committer | Thilo Bangert <bangert@gentoo.org> | 2009-04-09 18:56:04 +0000 |
commit | 9e1cb2c572069ab251b290768521d2b523481f98 (patch) | |
tree | a1cdb19d2cb320ebea168b3aea9e6d6ac842ede6 /www-servers/spawn-fcgi | |
parent | Package moved from net-www to www-plugins, bug 265569. (diff) | |
download | historical-9e1cb2c572069ab251b290768521d2b523481f98.tar.gz historical-9e1cb2c572069ab251b290768521d2b523481f98.tar.bz2 historical-9e1cb2c572069ab251b290768521d2b523481f98.zip |
keepdir - fix init script for old baselayout (bug #265454)- some minor cleanups
Package-Manager: portage-2.2_rc26/cvs/Linux i686
Diffstat (limited to 'www-servers/spawn-fcgi')
-rw-r--r-- | www-servers/spawn-fcgi/ChangeLog | 7 | ||||
-rw-r--r-- | www-servers/spawn-fcgi/Manifest | 8 | ||||
-rw-r--r-- | www-servers/spawn-fcgi/files/spawn-fcgi.confd | 18 | ||||
-rw-r--r-- | www-servers/spawn-fcgi/files/spawn-fcgi.initd | 27 | ||||
-rw-r--r-- | www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild | 4 |
5 files changed, 35 insertions, 29 deletions
diff --git a/www-servers/spawn-fcgi/ChangeLog b/www-servers/spawn-fcgi/ChangeLog index eef0c419b2c6..3aa5a88d3cb9 100644 --- a/www-servers/spawn-fcgi/ChangeLog +++ b/www-servers/spawn-fcgi/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for www-servers/spawn-fcgi # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/ChangeLog,v 1.4 2009/04/07 08:39:00 bangert Exp $ +# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/ChangeLog,v 1.5 2009/04/09 18:56:03 bangert Exp $ + + 09 Apr 2009; Thilo Bangert <bangert@gentoo.org> files/spawn-fcgi.confd, + files/spawn-fcgi.initd, spawn-fcgi-1.6.1: + keepdir - fix init script for old baselayout (bug #265454)- some minor + cleanups 07 Apr 2009; Thilo Bangert <bangert@gentoo.org> files/spawn-fcgi.initd: make sure pidpath is available diff --git a/www-servers/spawn-fcgi/Manifest b/www-servers/spawn-fcgi/Manifest index 5c47bb1ba839..b8330c185830 100644 --- a/www-servers/spawn-fcgi/Manifest +++ b/www-servers/spawn-fcgi/Manifest @@ -1,6 +1,6 @@ -AUX spawn-fcgi.confd 2211 RMD160 a6f7f778fbe5eab7702a407c9761f537ecb43f83 SHA1 8c8eb892c06aedb3641d7bef692a24200df02f23 SHA256 4a5ce40facaea8bebdc519787111b32a24df82d313079a8e882d599ab4d2b344 -AUX spawn-fcgi.initd 2717 RMD160 5153768d05ac0946b5c06249d0fffaa42f40852a SHA1 3bc0009288b8b93ab408005ec7a28873ee9abba8 SHA256 9bd89c86cdcfd3c2cd3f15192b810997c991ac8a051b3e769360510ae9f8aeea +AUX spawn-fcgi.confd 2139 RMD160 db0e89fc9602f864cbd21b20b0235d1a4cb48610 SHA1 d0e87700f2387699f598b29a1338990de10193bc SHA256 d2e8246fdbbb6961d4286cf43a1a0e60110a14b215435fc25087a94ef06ad6e3 +AUX spawn-fcgi.initd 2690 RMD160 92a97c46a29a68c08a3ff6843bedd17d2c289688 SHA1 ba51e6cdaa437cfd3e5f7f6dc3348177cd831f50 SHA256 8ba3e5fc9e3b16a764ed880e3cdbbf97e7c385bdf78302ed9b92e213337232d0 DIST spawn-fcgi-1.6.1.tar.bz2 71975 RMD160 d906031b3ce40c4a7d682da8acd556f12e8f3fcb SHA1 e18db1367ac1e186972d02e4d9e67a3a34212fc2 SHA256 81301b74d66b8083f23e9c1e39d42fe71995cdf3d06d3beecf3a81a1782f523c -EBUILD spawn-fcgi-1.6.1.ebuild 834 RMD160 68e16ee083830aa035c5051a7ae464d6da4620f7 SHA1 5b94d69e68fb9dbf10d800c380061c643d0bb7a5 SHA256 eca2be8ef509a5532cf9b1b4d90880169b5025784573c6f62f0bbb42d4638d35 -MISC ChangeLog 848 RMD160 2acbda99d74f560398b0aca5220edea8f1e587b3 SHA1 682f4fb6a806bff3c840d9c206e3aa4359c09648 SHA256 4ab398c8d1e314277fc7936b435cd80705c20a53796f33aa00e439e033b27d96 +EBUILD spawn-fcgi-1.6.1.ebuild 836 RMD160 eaadba7af88122d0ff35394b8d473f068a16ac03 SHA1 d14e466d82fec0688a32af19a2af01b9a25f2830 SHA256 e44cbd0d9022a82a9de12268de13a1a16510d69e48937263a826ee8d4c1eb3fe +MISC ChangeLog 1051 RMD160 7c2f221ead29bade4d9f88013b5df7535ca42334 SHA1 2122c80430369eb3b5ed93cb7beb74bd2d56ae14 SHA256 7a8419748d57beb981a404aced097899c96bff235412d235cdc8abb6077938c9 MISC metadata.xml 454 RMD160 6d518892201f5edddc6a83e119384f5c57661d42 SHA1 37c722d45f2473c24620d92f5bc2b31e92f6385c SHA256 dad5c3b31bdf5cffbec7a56402ecc46a9ed1db288f9e27302ca3d53da5b0fe0c diff --git a/www-servers/spawn-fcgi/files/spawn-fcgi.confd b/www-servers/spawn-fcgi/files/spawn-fcgi.confd index 1c6fd1de1b7b..cbc5d000fd12 100644 --- a/www-servers/spawn-fcgi/files/spawn-fcgi.confd +++ b/www-servers/spawn-fcgi/files/spawn-fcgi.confd @@ -1,6 +1,6 @@ # Copyright 1999-2009 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.confd,v 1.2 2009/04/03 18:18:13 bangert Exp $ +# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/files/spawn-fcgi.confd,v 1.3 2009/04/09 18:56:04 bangert Exp $ # DO NOT MODIFY THIS FILE DIRECTLY! CREATE A COPY AND MODIFY THAT INSTEAD! @@ -31,10 +31,10 @@ FCGI_PORT=1234 # extension but not always. For PHP, you should usually point this to # /usr/bin/php-cgi. # -FCGI_PROGRAM=/path/to/application.fcgi +#FCGI_PROGRAM=/usr/bin/php-cgi +FCGI_PROGRAM= -# The number of child processes to spawn. The default is 1. For PHP -# applications, set this to 1 and use PHP_FCGI_CHILDREN instead. +# The number of child processes to spawn. The default is 1. # FCGI_CHILDREN=1 @@ -49,11 +49,10 @@ FCGI_CHROOT= FCGI_USER= FCGI_GROUP= -# If your application requires additional environment variables, you need to -# allow them here. Only the variables specified here, plus a few others -# mentioned in the init script are passed to the application. +# If your application requires additional environment variables, you may +# specify them here. See PHP example below. # -ALLOWED_ENV="" +ALLOWED_ENV= # PHP ONLY :: These two options are specific to PHP. The first is the number # of child processes to spawn. The second is the number of requests to be @@ -61,3 +60,6 @@ ALLOWED_ENV="" # #PHP_FCGI_CHILDREN=5 #PHP_FCGI_MAX_REQUESTS=500 +# +# For this to work you would set +# ALLOWED_ENV="PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS" diff --git a/www-servers/spawn-fcgi/files/spawn-fcgi.initd b/www-servers/spawn-fcgi/files/spawn-fcgi.initd index 3fc89950e2e5..38cbc2b57f39 100644 --- a/www-servers/spawn-fcgi/files/spawn-fcgi.initd +++ b/www-servers/spawn-fcgi/files/spawn-fcgi.initd @@ -1,7 +1,7 @@ #!/sbin/runscript # Copyright 1999-2009 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,v 1.4 2009/04/07 08:39:00 bangert Exp $ +# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/files/spawn-fcgi.initd,v 1.5 2009/04/09 18:56:04 bangert Exp $ PROGNAME=${SVCNAME#*.} SPAWNFCGI=/usr/bin/spawn-fcgi @@ -32,7 +32,14 @@ start() { return 1 fi - local X E OPTIONS SOCKET_OPTION PORT_OPTION RETVAL + if [ -z "${FCGI_PROGRAM}" ]; then + eerror "You need to specify which FCGI program you want" + eerror "spawn-fcgi to start." + eerror "Look at /etc/conf.d/spawn-fcgi.${PROGNAME}" + return 1 + fi + + local X E OPTIONS i RETVAL if [ -z "${FCGI_ADDRESS}" ]; then FCGI_ADDRESS=127.0.0.1 @@ -42,10 +49,6 @@ start() { FCGI_CHILDREN=1 fi - if [ -n "${PHP_FCGI_CHILDREN}" ]; then - OPTIONS="${OPTIONS} -C ${PHP_FCGI_CHILDREN}" - fi - if [ -n "${FCGI_CHROOT}" ]; then OPTIONS="${OPTIONS} -c ${FCGI_CHROOT}" fi @@ -58,27 +61,23 @@ start() { OPTIONS="${OPTIONS} -g ${FCGI_GROUP}" fi - ALLOWED_ENV="$ALLOWED_ENV USER GROUPS PHP_FCGI_MAX_REQUESTS RAILS_ENV TRAC_ENV_PARENT_DIR TRAC_ENV" unset E - for i in ${ALLOWED_ENV}; do - eval j='"$i"' + local j + eval j=$(echo \$"$i") [ -n "${j}" ] && E="${E} -e ${i}=${j}" done - #make sure pidfile dir exists - install -d "${PIDPATH}" -m 0700 -o root - ebegin "Starting FastCGI application ${PROGNAME}" X=0 while [ $X -lt ${FCGI_CHILDREN} ]; do X=$(($X+1)) - local P + local P SOCKET_OPTION INET_OPTION P=${PIDFILE}-${X}.pid [ -n "${FCGI_SOCKET}" ] && SOCKET_OPTION="-s ${FCGI_SOCKET}-${X}" [ -n "${FCGI_PORT}" ] && INET_OPTION="-a ${FCGI_ADDRESS} -p $((${FCGI_PORT} + ${X} - 1))" - start-stop-daemon --start --pidfile ${P} ${E} --exec ${SPAWNFCGI} -- \ + start-stop-daemon --start --pidfile ${P} ${E} --exec ${SPAWNFCGI} --name ${FCGI_PROGRAM} -- \ ${SOCKET_OPTION} ${INET_OPTION} -P ${P} ${OPTIONS} -- ${FCGI_PROGRAM} RETVAL=$? diff --git a/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild b/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild index c954fff56f9a..80998fff8706 100644 --- a/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild +++ b/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild,v 1.1 2009/04/01 10:12:17 bangert Exp $ +# $Header: /var/cvsroot/gentoo-x86/www-servers/spawn-fcgi/spawn-fcgi-1.6.1.ebuild,v 1.2 2009/04/09 18:56:03 bangert Exp $ EAPI="2" @@ -24,6 +24,6 @@ src_install() { newconfd "${FILESDIR}"/spawn-fcgi.confd spawn-fcgi newinitd "${FILESDIR}"/spawn-fcgi.initd spawn-fcgi #pidfile dir - dodir /var/run/spawn-fcgi + keepdir /var/run/spawn-fcgi fperms 0700 /var/run/spawn-fcgi } |