FROM node:lts-alpine
WORKDIR /usr/src/app
COPY package*.json ./
RUN npm install
# If you are building your code for production
# RUN npm ci --only=production
COPY . .
RUN npm run build
CMD [ "node", "dist/index.js" ]

If you want to build the code for production, we can use the following command. The explanation about the command npm ci can be found here.

0 commenti

Lascia un commento

Segnaposto per l'avatar