Dynavera/compose/dev/python/Dockerfile

23 lines
524 B
Text
Raw Normal View History

FROM python:3.12-bookworm
RUN apt-get update && apt-get install --no-install-recommends -y \
build-essential \
libpq-dev \
2025-12-20 20:40:23 +00:00
wait-for-it \
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
&& rm -rf /var/lib/apt/lists/*
ENV VIRTUAL_ENV=/venv \
PATH=/venv/bin:$PATH
RUN python -m venv /venv
WORKDIR /app
COPY requirements/base.txt .
RUN pip install --no-cache-dir --requirement base.txt
2025-12-20 20:40:23 +00:00
COPY ./compose/prod/start /start
RUN sed -i 's/\r$//g' /start && chmod +x /start
CMD ["/start"]