summaryrefslogtreecommitdiff
path: root/install/ishtar-prepare-instance
diff options
context:
space:
mode:
Diffstat (limited to 'install/ishtar-prepare-instance')
-rwxr-xr-xinstall/ishtar-prepare-instance14
1 files changed, 6 insertions, 8 deletions
diff --git a/install/ishtar-prepare-instance b/install/ishtar-prepare-instance
index f176d8f90..bafc6133d 100755
--- a/install/ishtar-prepare-instance
+++ b/install/ishtar-prepare-instance
@@ -271,12 +271,10 @@ EOF
sed -s "s|example_project|$INSTANCE|g;" \
$INSTANCE"/celery_app.py.sample" > \
$INSTANCE"/celery_app.py"
- if [ -d "$DIRECTORY" ]; then
- sed -s "s|#APP_NAME#|$INSTANCE|g;" \
- "install/monit.template" > \
- "/etc/monit/conf-available/celery-"$INSTANCE
- fi
-
+ mkdir -p /etc/monit/conf-available/
+ sed -s "s|#APP_NAME#|$INSTANCE|g;" \
+ "install/monit.template" > \
+ "/etc/monit/conf-available/celery-"$INSTANCE
fi
### __init__.py
@@ -388,8 +386,8 @@ EOF
if [ $USE_CELERY = 'yes' ]; then
SUPERVISOR=`which supervisorctl`
if [ $SUPERVISOR ]; then
- supervisorctl add celery_$INSTANCE
- supervisorctl start celery_$INSTANCE
+ supervisorctl reload || (true && cecho r "supervisorctl reload - failed")
+ supervisorctl start celery_$INSTANCE || (true && cecho r "supervisorctl start celery_$INSTANCE - failed")
fi
fi