Dockerfile aktualisiert

robbi-inspect
Robert Rapp 2023-12-07 03:11:46 +00:00
parent 771a847148
commit 63f795d4c9
1 changed files with 6 additions and 4 deletions

View File

@ -1,14 +1,16 @@
FROM node:18.14.2 FROM node:18.14.2 as builder
WORKDIR /app WORKDIR /app
ENV NODE_OPTIONS=--openssl-legacy-provider
COPY package*.json ./ COPY package*.json ./
RUN npm install RUN npm install
COPY . . COPY . .
FROM node:18.14.2 as run
WORKDIR /app
COPY package*.json ./
COPY --from=builder /app/.output /.output
EXPOSE 3000 EXPOSE 3000
RUN npm run build
CMD [ "npm", "run", "start" ] CMD [ "npm", "run", "start" ]