<p>How to create docker image for Flask applications and serve it for production with scalability </p>

<p>I need to deploy my flask app using docker container. As per docker principles it is recommended to run only one process inside a container. </p>

<p>But in Flask apps it is recommended uses wsgi servers which will spawn multiple process. </p>

<p>And flask inbuilt server is not recommended to use during production.
I checked lot of git repos and tutorials but most of them are using inbuilt flask server or gunincorn. But in gunicorn they are using multiples process</p>

<p>Can anybody suggest how to serve flask app in this case</p>

<p>You can use the gunicorn for falsk and write the docker file and create docker images for example</p>

<pre><code>FROM python:3.6
ADD . /app
WORKDIR /app
RUN pip install flask gunicorn
EXPOSE 8000
CMD ["gunicorn", "-b", "0.0.0.0:8000", "app"]
</code></pre>
