Skip to content

Commit

Permalink
Improve Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
micafer committed Nov 11, 2020
1 parent 3ea8ad3 commit 11d3233
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM python:3.8
FROM python:3.8.6-alpine3.12

RUN apk add --no-cache git

COPY . /app
WORKDIR /app/
Expand All @@ -7,18 +9,20 @@ COPY ./tosca-templates /opt/tosca-templates

ENV PYTHONPATH=/app

RUN pip3 install gunicorn==20.0.4 && pip install -r /app/requirements.txt
RUN apk add --no-cache --virtual .build-deps gcc libc-dev git \
&& pip3 install meinheld==1.0.2 gunicorn==20.0.4 && pip3 install -r /app/requirements.txt \
&& apk del .build-deps gcc libc-dev git

EXPOSE 5001

ENV WORKER_TYPE sync
ENV WORKER_TYPE "egg:meinheld#gunicorn_worker"
ENV TIMEOUT 180
ENV ENABLE_HTTPS False
ENV WORKERS 4

COPY ./docker/start.sh /start.sh

CMD ["/bin/bash","/start.sh"]
CMD ["/bin/sh","/start.sh"]



0 comments on commit 11d3233

Please sign in to comment.