noteshare.space/server/Dockerfile
Struchkov Mark 1d918a19d0
All checks were successful
continuous-integration/drone/push Build is passing
Исправление бага
2023-05-29 21:50:21 +03:00

26 lines
384 B
Docker

FROM node:16 AS BUILD_IMAGE
# install dependencies
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci
# Copy all local files into the image.
COPY . .
RUN npx prisma generate
RUN npm run build
# remove development dependencies
RUN npm prune --production
FROM node:16
WORKDIR /app
COPY --from=0 /app .
ENV PORT 8080
EXPOSE 8080
CMD ["node", "./build/src/server.js"]