blob: 5c1acdf8dfff12d9924cb04bf6d685c07544fe6b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
FROM registry.hub.docker.com/library/node:lts-buster-slim AS builder
WORKDIR .
COPY package.json .
RUN npm i --omit=dev
COPY . .
RUN npm run build
FROM registry.hub.docker.com/library/node:lts-buster-slim
USER node:node
WORKDIR .
COPY --from=builder --chown=node:node build build
COPY --from=builder --chown=node:node node_modules node_modules
COPY --chown=node:node package.json .
CMD ["node","build"]
|