From: Paul Tipper Date: Sat, 20 Nov 2010 19:28:39 +0000 (+0000) Subject: Slightly improved X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=5ce3db7d5d72944762bcd29c1e03de37bf1f2f86;p=p5sagit%2FOyster.git Slightly improved --- diff --git a/share/deploy/git/catalyst-restart.sh b/share/deploy/git/catalyst-restart.sh index bae2a8e..c117339 100644 --- a/share/deploy/git/catalyst-restart.sh +++ b/share/deploy/git/catalyst-restart.sh @@ -1,18 +1,20 @@ -#!/bin/sh +#!/bin/bash # Really this should suck less, its a crap version of this: # http://use.perl.org/~zzo/journal/34146 -PROJECT=foo -APP_PATH=/path/to/checkout +# Work out what our projects called, we must be called from the top level with +# a scripts/ directory + +RESTART_SCRIPT=$( find script/ -type f -name '*_fastcgi.pl' ) +#APP_PATH=/path/to/checkout FCGI_SOCKET_PATH=/tmp/$PROJECT.prod.socket PID_PATH=/var/run/$PROJECT.prod.pid case $1 in start) - echo -n "Starting PROD MT: mt_fastcgi.pl" - cd $APP_PATH - script/${PROJECT}_fastcgi.pl -l $FCGI_SOCKET_PATH -p $PID_PATH -d -n 5 + echo -n "Starting PROD: $RESTART_SCRIPT" + $RESTART_SCRIPT -l $FCGI_SOCKET_PATH -p $PID_PATH -d -n 5 echo # make real sure it's started