From b4a690d84edfff4441b9e500ad26ff2de459ad30 Mon Sep 17 00:00:00 2001 From: LDericher <40151420+ldericher@users.noreply.github.com> Date: Wed, 4 Aug 2021 19:09:25 +0200 Subject: [PATCH] Docker --- Dockerfile | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 578e0f7..ec37225 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,21 +5,27 @@ ENV PYTHONUNBUFFERED 1 WORKDIR "/app" RUN set -ex; \ - pip3 install pipenv; + pip3 install \ + --no-cache-dir --no-color --disable-pip-version-check --no-python-version-warning \ + pipenv \ + ; COPY Pipfile Pipfile.lock ./ RUN set -ex; \ - \ - # install build prerequisites + # install prerequisites apk add --no-cache \ - build-base \ - jpeg-dev \ - zlib-dev \ + g++ \ + jpeg-dev \ + zlib-dev \ ; \ - pipenv sync; \ - # remove build prerequisites - apk del --no-cache build-base; + # build/install local packages + pipenv install --deploy; \ + pipenv --clear; \ + # remove build-only prerequisites + apk del --no-cache \ + g++ \ + ; COPY . .