forked from CodingPirates/forenings_medlemmer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
36 lines (22 loc) · 801 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
FROM python:3.8
WORKDIR /app
RUN apt-get update && \
apt-get install -y graphviz
RUN wget -O /tmp/sass.tar.gz https://github.com/sass/dart-sass/releases/download/1.25.0/dart-sass-1.25.0-linux-x64.tar.gz \
&& tar xf /tmp/sass.tar.gz -C /bin \
&& chmod -R a+rx /bin/dart-sass/
COPY pyproject.toml pyproject.toml
COPY poetry.lock poetry.lock
ENV POETRY_VIRTUALENVS_CREATE false
RUN pip install --upgrade pip \
&& pip install poetry \
&& poetry install
EXPOSE 8000
COPY entrypoint.sh entrypoint.sh
ENTRYPOINT ["/app/entrypoint.sh"]
# Force stdin, stdout and stderr to be totally unbuffered.
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
COPY . /app
# Set the default command to be executed.
CMD gunicorn forenings_medlemmer.wsgi:application --bind 0.0.0.0:$PORT