Files
Notfellchen/Dockerfile

23 lines
634 B
Docker

FROM python:3.11-slim
# Use 3.11 to avoid django.core.exceptions.ImproperlyConfigured: Error loading psycopg2 or psycopg module
LABEL org.opencontainers.image.authors="Julian-Samuel Gebühr"
ENV DOCKER_BUILD=true
RUN apt update
RUN apt install gettext -y
RUN apt install libpq-dev gcc -y
COPY . /app
WORKDIR /app
RUN mkdir /app/data/static -p
RUN mkdir /app/data/media
RUN pip install --no-cache-dir -e . # Without the -e the library static folder will not be copied by collectstatic!
RUN nf collectstatic --noinput
RUN nf compilemessages --ignore venv
COPY docker/entrypoint.sh /bin/notfellchen
EXPOSE 7345
CMD ["notfellchen"]