2018-10-26 07:58:32 +00:00
|
|
|
FROM python:3-alpine3.6
|
|
|
|
|
|
|
|
ENV PYTHONUNBUFFERED=1
|
|
|
|
|
|
|
|
RUN apk add --no-cache linux-headers bash gcc \
|
|
|
|
musl-dev libjpeg-turbo-dev libpng libpq \
|
|
|
|
postgresql-dev uwsgi uwsgi-python3 git \
|
2018-11-10 05:41:12 +00:00
|
|
|
zlib-dev libmagic libffi-dev libressl-dev python3-dev openldap-dev
|
2018-10-26 07:58:32 +00:00
|
|
|
|
|
|
|
WORKDIR /site
|
|
|
|
|
|
|
|
ADD requirements.txt /site/
|
|
|
|
RUN pip install -U -r /site/requirements.txt
|
|
|
|
|
|
|
|
COPY ./ /site
|
2018-10-26 09:23:49 +00:00
|
|
|
CMD bash -c 'python3 manage.py migrate --noinput && python3 manage.py collectstatic --noinput && python3 manage.py create_test_users && uwsgi --ini=/site/uwsgi.ini'
|