Update 'nestjs.Dockerfile'
This commit is contained in:
parent
c43b9bda4e
commit
0649a6cb09
@ -31,7 +31,8 @@ WORKDIR /usr/src/app
|
||||
|
||||
COPY --chown=node:node package*.json ./
|
||||
|
||||
# In the previous development stage we ran `npm ci` which installed all dependencies, so we can copy over the node_modules directory from the development image
|
||||
# In the previous development stage we ran `npm ci` which installed all dependencies
|
||||
# so we can copy over the node_modules directory from the development image
|
||||
COPY --chown=node:node --from=development /usr/src/app/node_modules ./node_modules
|
||||
|
||||
COPY --chown=node:node . .
|
||||
@ -47,9 +48,9 @@ RUN npm ci --omit=dev && npm cache clean --force
|
||||
|
||||
USER node
|
||||
|
||||
###################
|
||||
# PRODUCTION
|
||||
###################
|
||||
##############
|
||||
# PRODUCTION #
|
||||
##############
|
||||
|
||||
FROM node:18-alpine As production
|
||||
|
||||
|
Reference in New Issue
Block a user