mirror of
https://github.com/jpetazzo/container.training.git
synced 2026-05-17 06:16:37 +00:00
For educational purposes, the RNG service is meant to process only one request at a time (without concurrency). But the flask server now defaults to a multi-threaded implementation, which defeats our original purpose. So here we disable threading to restore the original behavior.
8 lines
174 B
Docker
8 lines
174 B
Docker
FROM python:alpine
|
|
WORKDIR /app
|
|
RUN pip install Flask
|
|
COPY rng.py .
|
|
ENV FLASK_APP=rng FLASK_RUN_HOST=:: FLASK_RUN_PORT=80
|
|
CMD ["flask", "run", "--without-threads"]
|
|
EXPOSE 80
|