Dockerfile 596 Bytes
Newer Older
1 2
FROM python:3-slim

Vincent Martinez committed
3 4 5 6 7 8 9
# Add french locale
RUN apt update && \
    apt install -y --no-install-recommends locales && \
    rm -rf /var/lib/apt/lists/* && \
    sed -i '/^#.* fr_FR.UTF-8 /s/^#//' /etc/locale.gen && \
    locale-gen

10 11 12 13 14 15 16 17 18 19 20
# Virtual env:
ENV VIRTUAL_ENV=/opt/venv
RUN python3 -m venv $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"

WORKDIR /home/app

# Install dependencies:
COPY requirements.txt /home/app/
RUN pip install -r requirements.txt

21 22
# Setup volume to be able to dev application locally
VOLUME /home/app
23 24 25 26

# Run the application:
EXPOSE 8080
CMD ["./launch.sh", "0.0.0.0", "8080"]