mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-09-17 17:16:38 +08:00
chore: optimize Dockerfile for multi-directory npm installation and build
This commit is contained in:
parent
0a6273fc08
commit
eb6da573a3
18
Dockerfile
18
Dockerfile
@ -4,17 +4,15 @@ WORKDIR /web
|
|||||||
COPY ./VERSION .
|
COPY ./VERSION .
|
||||||
COPY ./web .
|
COPY ./web .
|
||||||
|
|
||||||
WORKDIR /web/default
|
RUN npm install --prefix /web/default & \
|
||||||
RUN npm install
|
npm install --prefix /web/berry & \
|
||||||
RUN DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat VERSION) npm run build
|
npm install --prefix /web/air & \
|
||||||
|
wait
|
||||||
|
|
||||||
WORKDIR /web/berry
|
RUN DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat /web/default/VERSION) npm run build --prefix /web/default & \
|
||||||
RUN npm install
|
DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat /web/berry/VERSION) npm run build --prefix /web/berry & \
|
||||||
RUN DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat VERSION) npm run build
|
DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat /web/air/VERSION) npm run build --prefix /web/air & \
|
||||||
|
wait
|
||||||
WORKDIR /web/air
|
|
||||||
RUN npm install
|
|
||||||
RUN DISABLE_ESLINT_PLUGIN='true' REACT_APP_VERSION=$(cat VERSION) npm run build
|
|
||||||
|
|
||||||
FROM golang:alpine AS builder2
|
FROM golang:alpine AS builder2
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user