-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathDockerfile
38 lines (34 loc) · 952 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
37
38
FROM python:3.9-bullseye
RUN curl -sL https://deb.nodesource.com/setup_14.x | bash -
run apt-get update && apt-get install -y \
binutils \
gdal-bin \
gettext \
git \
gunicorn \
libfreetype6-dev \
libgeos-dev \
libjpeg-dev \
liblcms2-dev \
memcached \
poppler-utils \
postgresql-common \
zlib1g-dev \
nodejs \
libgettextpo-dev \
libgraphviz-dev
run mkdir /home/aplikace -p
WORKDIR "/home/aplikace"
ARG UID
RUN useradd test --uid $UID
RUN chsh test -s /bin/bash
RUN mkdir /home/test ; chown test /home/test ; chgrp test /home/test
RUN npm install -g bower
RUN mkdir -p /var/log/django/
copy requirements.txt requirements.txt
RUN su test ; pip3 install --default-timeout=100 -r requirements.txt
copy . .
RUN bash -c "export SECRET_KEY='fake_key'; \
python3 manage.py bower install \
&& python3 manage.py compilemessages --ignore=third-party/* \
&& python3 manage.py collectstatic --noinput"