Avoid: "WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead."
ayelencasamassa opened this issue · 2 comments
Greetings.
I am using presidio with k8s and I am getting:
"WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead."
How can fix that?
Images:
mcr.microsoft.com/presidio-analyzer:2.2.354
mcr.microsoft.com/presidio-anonymizer:2.2.354
Thanks!
@SharonHart @roeybc can you please provide your guidance?
We try to define our images as standalone as possible, so that they don't force or suggest a specific way of to host or deploy the application, as this should be up to the client depending on it needs.
If you want to host a Flask application yourself, or in a IaaS k8s platform, the recommendation is to use a WSGI server (such as uWSGI, Gunicorn), it can be on the same container. In that case, you can override the Dockerfile CMD or ENTRYPOINT to work with WSGI. example
Deploying to a PaaS solution, like Azure App Service, which is a sample we provide in the repo, do not require to maintain a WSGI server since it is built in the platform, and behind the scenes Gunicorn is used