From 355038a91ab6ce73b80a011bfbe2a5f708dccda0 Mon Sep 17 00:00:00 2001 From: Jaime Baez Date: Mon, 4 Jul 2022 20:47:25 +0200 Subject: [PATCH] Use `npm ci` for installing pacakages (#304) --- machine-learning/Dockerfile | 4 ++-- server/Dockerfile | 2 +- web/Dockerfile | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/machine-learning/Dockerfile b/machine-learning/Dockerfile index 38aed3759d..3d16b2084e 100644 --- a/machine-learning/Dockerfile +++ b/machine-learning/Dockerfile @@ -1,4 +1,4 @@ -FROM node:16-bullseye-slim +FROM node:16-bullseye-slim ARG DEBIAN_FRONTEND=noninteractive @@ -9,7 +9,7 @@ COPY package.json package-lock.json ./ RUN apt-get update RUN apt-get install gcc g++ make cmake python3 python3-pip ffmpeg -y -RUN npm install +RUN npm ci COPY . . diff --git a/server/Dockerfile b/server/Dockerfile index 1c1c297969..cd2ff82e84 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -8,7 +8,7 @@ COPY package.json package-lock.json ./ RUN apk add --update-cache build-base python3 libheif vips-dev vips ffmpeg -RUN npm install --legacy-peer-deps +RUN npm ci COPY . . diff --git a/web/Dockerfile b/web/Dockerfile index bb442e6045..8d3c500ed3 100644 --- a/web/Dockerfile +++ b/web/Dockerfile @@ -7,9 +7,9 @@ RUN chown node:node /usr/src/app COPY --chown=node:node package*.json ./ -RUN apk add --update-cache build-base python3 +RUN apk add --update-cache build-base python3 -RUN npm install +RUN npm ci COPY --chown=node:node . . @@ -29,9 +29,9 @@ RUN chown node:node /usr/src/app COPY --chown=node:node package*.json ./ COPY --chown=node:node . . -RUN apk add --update-cache build-base python3 +RUN apk add --update-cache build-base python3 -RUN npm install +RUN npm ci EXPOSE 3000