diff --git a/.gitignore b/.gitignore index ee039fcb85..499f6b02e9 100644 --- a/.gitignore +++ b/.gitignore @@ -154,4 +154,8 @@ resources/commit_id watcher *.lock -**/bucket \ No newline at end of file +**/bucket + +# local scripts +dummy_kill.sh +dummy_launch.sh \ No newline at end of file diff --git a/scripts/start.sh b/scripts/start.sh index aedcca2202..2206f9c25b 100755 --- a/scripts/start.sh +++ b/scripts/start.sh @@ -5,9 +5,18 @@ set -e CUR_DIR=$(cd "$(dirname "$0")" && pwd) BASE_DIR=$(dirname "$CUR_DIR") +min() { + echo $(( $1 < $2 ? $1 : $2 )) +} + +workers=$(min 30 ${NB_WORKERS_ANTARES:-17}) # default to 17 and max is 30 + if [ -z "$1" ] ; then sh $CUR_DIR/pre-start.sh - gunicorn --config $BASE_DIR/conf/gunicorn.py --worker-class=uvicorn.workers.UvicornWorker antarest.wsgi:app + for ((i=0; i