Review this generated Dockerfile before it enters the release pipeline.
Build a reproducible, least-privilege Node 24 image that installs locked dependencies, serves port 3000, and shuts down cleanly.
dockerfile
# syntax=docker/dockerfile:1
FROM node:latest AS build
WORKDIR /app
ARG NPM_TOKEN
COPY package*.json ./
RUN echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc \
&& npm install
COPY . .
RUN npm run build
FROM node:latest
WORKDIR /app
COPY --from=build /app /app
ENV NODE_ENV=production
USER root
EXPOSE 3000
HEALTHCHECK CMD curl -f http://localhost:3000/health
CMD node app.mjs
generated code is illustrative, not from any one model