2023-07-28 08:36:33 +02:00
|
|
|
FROM node:18 AS build
|
2020-04-29 07:53:07 +02:00
|
|
|
|
2020-06-18 11:46:24 +02:00
|
|
|
WORKDIR /opt/node_app
|
|
|
|
|
2024-05-07 14:30:58 +02:00
|
|
|
COPY . .
|
|
|
|
|
|
|
|
# do not ignore optional dependencies:
|
|
|
|
# Error: Cannot find module @rollup/rollup-linux-x64-gnu
|
|
|
|
RUN yarn --network-timeout 600000
|
2020-06-18 11:46:24 +02:00
|
|
|
|
|
|
|
ARG NODE_ENV=production
|
|
|
|
|
2021-02-20 13:47:17 +01:00
|
|
|
RUN yarn build:app:docker
|
2020-04-29 07:53:07 +02:00
|
|
|
|
2024-05-07 14:30:58 +02:00
|
|
|
FROM nginx:1.24-alpine
|
2020-04-29 07:53:07 +02:00
|
|
|
|
2024-05-07 14:30:58 +02:00
|
|
|
COPY --from=build /opt/node_app/excalidraw-app/build /usr/share/nginx/html
|
2020-04-29 07:53:07 +02:00
|
|
|
|
|
|
|
HEALTHCHECK CMD wget -q -O /dev/null http://localhost || exit 1
|