mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-25 18:31:15 +02:00
Remove the extra "deps" step
This step can be done as part of the build (faster and more reliable).
This commit is contained in:
19
Dockerfile
19
Dockerfile
@@ -1,25 +1,12 @@
|
|||||||
FROM node:14-alpine AS deps
|
FROM node:14-alpine AS build
|
||||||
|
|
||||||
ARG REACT_APP_INCLUDE_GTAG=false
|
|
||||||
|
|
||||||
RUN mkdir /opt/node_app && chown node:node /opt/node_app
|
|
||||||
WORKDIR /opt/node_app
|
|
||||||
|
|
||||||
USER node
|
|
||||||
|
|
||||||
COPY package.json package-lock.json ./
|
|
||||||
RUN npm install --no-optional && npm cache clean --force
|
|
||||||
ENV PATH /opt/node_app/node_modules/.bin:$PATH
|
|
||||||
|
|
||||||
WORKDIR /opt/node_app
|
WORKDIR /opt/node_app
|
||||||
COPY . .
|
COPY . .
|
||||||
|
RUN npm i --no-optional
|
||||||
|
|
||||||
FROM node:14-alpine AS build
|
ARG REACT_APP_INCLUDE_GTAG=false
|
||||||
|
|
||||||
ARG NODE_ENV=production
|
ARG NODE_ENV=production
|
||||||
|
|
||||||
WORKDIR /opt/node_app
|
|
||||||
COPY --from=deps /opt/node_app .
|
|
||||||
RUN npm run build:app:docker
|
RUN npm run build:app:docker
|
||||||
|
|
||||||
FROM nginx:1.17-alpine
|
FROM nginx:1.17-alpine
|
||||||
|
Reference in New Issue
Block a user