mirror of
https://github.com/discourse/discourse.git
synced 2024-11-27 00:23:41 +08:00
Revert "Avoid hardcoded value in unicorn_launcher
."
This seems to be causing problem with the unicorn master pid
tracking so revert for now.
This reverts commit 09d0216e84
.
This commit is contained in:
parent
09d0216e84
commit
a8368318fe
|
@ -15,14 +15,9 @@ function on_reload()
|
|||
{
|
||||
echo "Reloading unicorn"
|
||||
kill -s USR2 $UNICORN_PID
|
||||
|
||||
while [ -z "$NEW_UNICORN_PID" ]; do
|
||||
echo "waiting for new unicorn master pid"
|
||||
NEW_UNICORN_PID=`ps -f --ppid $UNICORN_PID | grep 'unicorn master' | grep -v worker | awk '{ print $2 }'`
|
||||
sleep 1
|
||||
done
|
||||
|
||||
sleep 10
|
||||
curl $LOCAL_WEB &> /dev/null
|
||||
NEW_UNICORN_PID=`ps -f --ppid $UNICORN_PID | grep unicorn | grep -v worker | awk '{ print $2 }'`
|
||||
kill -s QUIT $UNICORN_PID
|
||||
echo "Old pid is: $UNICORN_PID New pid is: $NEW_UNICORN_PID"
|
||||
UNICORN_PID=$NEW_UNICORN_PID
|
||||
|
|
Loading…
Reference in New Issue
Block a user