From cc984200097d7bf9e183ea2921675bfbac1c12e9 Mon Sep 17 00:00:00 2001 From: AbhilashKD <124042593+AbhilashKD@users.noreply.github.com> Date: Thu, 29 Aug 2024 20:15:34 +0530 Subject: [PATCH] Update Dockerfile --- Dockerfile | 28 +++++++--------------------- 1 file changed, 7 insertions(+), 21 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8b3ca39..f937dfb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,22 +1,8 @@ -FROM node:slim - -# Create app directory +FROM node:20 as dependencies WORKDIR /app - -# Install app dependencies -# A wildcard is used to ensure both package.json AND package-lock.json are copied -# where available (npm@5+) -COPY package*.json ./ - -#RUN npm cache clean --force - -RUN npm install -RUN npm i --save @nestjs/config -# If you are building your code for production -# RUN npm ci --only=production - -# Bundle app source -COPY . . - -EXPOSE 3000 -CMD [ "npm", "run","start" ] +COPY . ./ +RUN npm i --force +RUN npm install fcm-node --force +RUN apt-get update +EXPOSE 4000 +CMD ["npm", "start"]