Skip to content

Commit

Permalink
Start of re-introducing docker
Browse files Browse the repository at this point in the history
  • Loading branch information
KiOui committed Dec 13, 2023
1 parent 054a106 commit f2cfd7b
Show file tree
Hide file tree
Showing 4 changed files with 495 additions and 508 deletions.
31 changes: 31 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
FROM python:3.11

ENV PYTHONUNBUFFERED 1
ENV DJANGO_SETTINGS_MODULE tosti.settings.production
ENV PATH /root/.poetry/bin:${PATH}

ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]

WORKDIR /tosti/src
COPY resources/entrypoint.sh /usr/local/bin/entrypoint.sh
COPY poetry.lock pyproject.toml /tosti/src/

RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install --yes --quiet --no-install-recommends postgresql-client && \
rm --recursive --force /var/lib/apt/lists/* && \
\
mkdir --parents /tosti/src/ && \
mkdir --parents /tosti/log/ && \
mkdir --parents /tosti/static/ && \
mkdir --parents /tosti/media/ && \
mkdir --parents /tosti/cache/ && \
mkdir --parents /tosti/saml/ && \
chmod +x /usr/local/bin/entrypoint.sh && \
\
curl -sSL https://install.python-poetry.org | python3 - && \
export PATH="/root/.local/bin:$PATH" && \
poetry config --no-interaction --no-ansi virtualenvs.create false && \
poetry install --no-interaction --no-ansi --no-dev


COPY website /tosti/src/website/
Loading

0 comments on commit f2cfd7b

Please sign in to comment.