Change Dockerfiles and docker-compose file
The reason for this change is to reduce the image size for the different containers
This commit is contained in:
parent
e32ab08b7d
commit
6a3d510cad
7 changed files with 74 additions and 29 deletions
|
@ -1,4 +1,4 @@
|
|||
FROM node:latest
|
||||
FROM node:slim AS build
|
||||
|
||||
# set working directory
|
||||
WORKDIR /app
|
||||
|
@ -10,7 +10,9 @@ ENV PATH /app/node_modules/.bin:$PATH
|
|||
COPY package.json ./
|
||||
COPY package-lock.json ./
|
||||
|
||||
RUN npm install
|
||||
RUN npm install && npm cache clean --force
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
# add app
|
||||
COPY . ./
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue