From 93423f7e55165e42920c1905fc4f65aab7ab18a3 Mon Sep 17 00:00:00 2001 From: Your Name Date: Sun, 8 Sep 2024 22:48:19 +0200 Subject: [PATCH] fix --- Dockerfile | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index f9449ff..ebeb75f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,15 +1,8 @@ # syntax=docker/dockerfile:1 -#FROM node:latest +# cacheble npm install stage that only reruns if package.json actually changes. FROM node:22 AS builder -#build tools for alpine -# RUN apk --no-cache add python3 -# RUN apk --no-cache add make -# RUN apk --no-cache add gcc -# RUN apk --no-cache add musl-dev -# RUN apk --no-cache add g++ - ENV NODE_ENV=production WORKDIR /app @@ -17,7 +10,7 @@ WORKDIR /app COPY ["package.json", "package-lock.json*", "./"] -RUN NODE_ENV=development npm install +RUN NODE_ENV=production npm install COPY . .