gunicorn with --preload

To only load the code once (and start autotrim once)
master
pictuga 2020-10-01 00:05:39 +02:00
parent 056a1b143f
commit 6192ff4081
2 changed files with 2 additions and 2 deletions

View File

@ -5,4 +5,4 @@ RUN apk add python3 py3-lxml py3-gunicorn py3-pip git
ADD . /app ADD . /app
RUN pip3 install /app RUN pip3 install /app
CMD gunicorn --bind 0.0.0.0:8080 -w 4 morss CMD gunicorn --bind 0.0.0.0:8080 -w 4 --preload morss

View File

@ -186,7 +186,7 @@ uwsgi --http :8080 --plugin python --wsgi-file main.py
#### Using Gunicorn #### Using Gunicorn
```shell ```shell
gunicorn morss gunicorn --preload morss
``` ```
#### Using docker #### Using docker