mirror of
https://github.com/excalidraw/excalidraw.git
synced 2024-11-10 11:35:52 +01:00
5b63371c14
* .eslintrc.json is required to build using react-scripts * Remove the extra "deps" step This step can be done as part of the build (faster and more reliable). * Add a GitHub Actions to build the Docker image Make sure that "docker build" is working on every pull request before landing on master. * Update package-lock.json * Add .prettierrc in the Docker image to avoid warnings in the build step * Revert "Update package-lock.json" This reverts commit 7ef2eaadfae610771987bc8155670b895c139e7b. * Make sure that the 'node_modules' layer can be cached if package and package-lock.json didn't changed
19 lines
363 B
Docker
19 lines
363 B
Docker
FROM node:14-alpine AS build
|
|
|
|
WORKDIR /opt/node_app
|
|
|
|
COPY package.json package-lock.json ./
|
|
RUN npm i --no-optional
|
|
|
|
ARG REACT_APP_INCLUDE_GTAG=false
|
|
ARG NODE_ENV=production
|
|
|
|
COPY . .
|
|
RUN npm run build:app:docker
|
|
|
|
FROM nginx:1.17-alpine
|
|
|
|
COPY --from=build /opt/node_app/build /usr/share/nginx/html
|
|
|
|
HEALTHCHECK CMD wget -q -O /dev/null http://localhost || exit 1
|