wildflock/Dockerfile
Lauri Võsandi de2c82617f
All checks were successful
ci/woodpecker/push/build/1 Pipeline was successful
ci/woodpecker/push/build/2 Pipeline was successful
ci/woodpecker/push/manifest Pipeline was successful
Use mirror.gcr.io for prod Docker stage as well
2024-08-15 23:00:19 +03:00

27 lines
547 B
Docker

FROM mirror.gcr.io/library/node:18-alpine as dev
RUN apk add netcat-openbsd
RUN npm config set update-notifier false
WORKDIR /app
COPY . /app
COPY src ./
RUN npm ci --silent
RUN npm run compile
ENTRYPOINT npm run start
FROM mirror.gcr.io/node:18-alpine AS prod
RUN npm config set update-notifier false
WORKDIR /app
COPY --from=dev /app/package.json /app/package-lock.json /app/
COPY config /app/config
COPY --from=dev /app/lib /app/lib
COPY --from=dev /app/public /app/public
RUN npm ci --only=production --silent
CMD ["npm", "start"]