From 6a261656479f59a546ddfd6f6f0bfa582c644856 Mon Sep 17 00:00:00 2001 From: MichiK <6341204+der-michik@users.noreply.github.com> Date: Tue, 4 Dec 2018 02:27:10 +0100 Subject: Improve Docker build caching First install the dependencies, then copy the files from the build context into the image. This allows for more caching during rebuilds when files change and rebuilds are much faster. --- contrib/nginx/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'contrib/nginx/Dockerfile') diff --git a/contrib/nginx/Dockerfile b/contrib/nginx/Dockerfile index e838d368..609792c0 100644 --- a/contrib/nginx/Dockerfile +++ b/contrib/nginx/Dockerfile @@ -1,8 +1,8 @@ FROM node:8-alpine as themes WORKDIR /app +RUN apk add --no-cache yarn COPY resources/assets/ /app/resources/assets COPY .babelrc package.json webpack.config.js /app/ -RUN apk add --no-cache yarn RUN yarn install RUN yarn build -- cgit v1.2.3-54-g00ecf