diff --git a/server/run.sh b/server/run.sh index f13b057..fb6a82e 100644 --- a/server/run.sh +++ b/server/run.sh @@ -1,4 +1,6 @@ #!/usr/bin/env bash chown compiler:compiler /spj echo 0 > /tmp/counter -gunicorn --workers 4 --threads 4 --error-logfile /log/gunicorn.log --bind 0.0.0.0:8080 server:wsgiapp +core=$(grep --count ^processor /proc/cpuinfo) +n=$(($core*4)) +gunicorn --workers $n --threads $n --error-logfile /log/gunicorn.log --time 600 --bind 0.0.0.0:8080 server:wsgiapp \ No newline at end of file