diff options
author | Markus Pöschl <Poeschl@users.noreply.github.com> | 2021-05-15 11:06:17 +0200 |
---|---|---|
committer | Markus Pöschl <Poeschl@users.noreply.github.com> | 2021-05-15 15:44:43 +0200 |
commit | 4794c2b6ab4b33c6a20dade1bf773bbe1f9dc6f6 (patch) | |
tree | cec1d96cf1605b697cd50c3f6573dbb823a84890 /docker-files | |
parent | cec2c453bcf64c3d674156421d76099fbfa60a8c (diff) |
Install dependencies before installing from pypi for better layer caching
Diffstat (limited to 'docker-files')
-rw-r--r-- | docker-files/debian.Dockerfile | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/docker-files/debian.Dockerfile b/docker-files/debian.Dockerfile index f9f1777a..da80e309 100644 --- a/docker-files/debian.Dockerfile +++ b/docker-files/debian.Dockerfile @@ -19,7 +19,11 @@ RUN apt-get update && \ FROM build as remoteInstall -# Force rebuild otherwise it could be cached without rerun +# Install the dependencies beforehand to make them cacheable +COPY requirements.txt . +RUN pip3 install --no-cache-dir --user -r requirements.txt + +# Force install otherwise it could be cached without rerun ARG CHANGING_ARG RUN pip3 install --no-cache-dir --user glances[all] |