diff --git a/api-server/Dockerfile.prod b/api-server/Dockerfile.prod index e751529..1ae2176 100644 --- a/api-server/Dockerfile.prod +++ b/api-server/Dockerfile.prod @@ -5,8 +5,8 @@ WORKDIR /app/server # install packages COPY requirements.txt ./ RUN pip install --no-cache-dir -r requirements.txt -RUN pip install gunicorn==23.0.0 gevent==24.2.1 gevent-websocket==0.10.1 +RUN pip install gunicorn==23.0.0 COPY . . -CMD ["gunicorn", "-k", "geventwebsocket.gunicorn.workers.GeventWebSocketWorker", "-w", "1", "--threads", "100", "-b", "0.0.0.0:8080", "app:app"] \ No newline at end of file +CMD ["gunicorn", "--worker-class", "eventlet", "-w", "1", "-b", "0.0.0.0:8080", "app:app"] \ No newline at end of file diff --git a/api-server/app.py b/api-server/app.py index c49896e..f4828a0 100644 --- a/api-server/app.py +++ b/api-server/app.py @@ -102,7 +102,5 @@ def handle_disconnect(): if __name__ == '__main__': if os.getenv('TESTING', True): socketio.run(app, debug=True, allow_unsafe_werkzeug=True) - elif os.getenv('PRODUCTION', True): - socketio.run(app, async_mode='gevent') else: socketio.run(app, debug=True) \ No newline at end of file