diff --git a/src/system-configs/upstart-configs/units/webida-batch.conf b/src/system-configs/upstart-configs/units/webida-batch.conf index 068836a..1b4d472 100644 --- a/src/system-configs/upstart-configs/units/webida-batch.conf +++ b/src/system-configs/upstart-configs/units/webida-batch.conf @@ -5,10 +5,6 @@ author "Webida team" start on startup stop on shutdown -# Set the priv of scripts -# If this not not set, the Webida server will be run as root and it'll be a disaster. -setuid webida - # This let upstart track the child process of forever. # Because forever spawns another monitor process and exits, this is required. expect fork @@ -21,7 +17,7 @@ env NODE_ENV='production' env SCRIPT="unit-manager.js svc=batch0" script - exec forever --sourceDir "$SERVER_ROOT/$SERVER_DIR" -a -l $LOG --minUptime 5000 --spinSleepTime 2000 start $SCRIPT + exec forever --sourceDir "$WEBIDA_HOME/$SERVER_DIR" -a -l $LOG --minUptime 5000 --spinSleepTime 2000 start $SCRIPT end script pre-stop script diff --git a/src/system-configs/upstart-configs/units/webida-proxy.conf b/src/system-configs/upstart-configs/units/webida-proxy.conf index f736165..048260c 100644 --- a/src/system-configs/upstart-configs/units/webida-proxy.conf +++ b/src/system-configs/upstart-configs/units/webida-proxy.conf @@ -15,7 +15,7 @@ env NODE_ENV='production' env SCRIPT="unit-manager.js svc=proxy0" script - exec forever --sourceDir "$SERVER_ROOT/$SERVER_DIR" -a -l $LOG --minUptime 5000 --spinSleepTime 2000 start $SCRIPT + exec forever --sourceDir "$WEBIDA_HOME/$SERVER_DIR" -a -l $LOG --minUptime 5000 --spinSleepTime 2000 start $SCRIPT end script pre-stop script