diff --git a/Dockerfile.nestjs b/Dockerfile.nestjs index ade56704f..e131a1617 100644 --- a/Dockerfile.nestjs +++ b/Dockerfile.nestjs @@ -1,9 +1,5 @@ FROM node:22-alpine -ENV \ - NODE_ENV=production \ - PORT=5030 - ENV \ REGISTRY_UID=10011 \ REGISTRY_GID=10011 @@ -22,6 +18,12 @@ RUN cd api-node && yarn install --frozen-lockfile COPY . . +# Set to production environment +# Importantly, after installing deps, otherwise dev deps aren't installed +ENV \ + NODE_ENV=production \ + PORT=5030 + WORKDIR /work/api-node # Build the application