forked from dvnrsn/toggle-meister
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
34 lines (26 loc) · 836 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
FROM python:3.7-alpine
ENV PYCURL_SSL_LIBRARY=openssl \
PYTHONPATH=. \
DOCKER=True
# compile requirements for some python libraries
RUN apk --no-cache add curl-dev bash postgresql-dev \
build-base libffi-dev libressl-dev tini && \
python3 -m pip install invoke alembic poetry
# install python reqs
COPY ["pyproject.toml", "pyproject.lock", "/app/"]
WORKDIR /app
RUN export PYCURL_SSL_LIBRARY=openssl && \
poetry config virtualenvs.create false && \
poetry install -vvv --no-dev
# build frontend
COPY tmeister/static /app/tmeister/static
RUN apk --no-cache add nodejs npm git && \
cd /app/tmeister/static && \
npm install && \
npm run build && \
apk --no-cache del nodejs git && \
rm -rf node_modules spec src bin && \
cd /app
EXPOSE 8445
CMD ["tini", "./startup.sh"]
COPY . /app