mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-09-21 21:50:49 +02:00
🐋 refactor(Dockerfile.multi): Optimize client build by caching npm install step (#2275)
* 🐋 fix(Dockerfile): Optimize client build by caching npm install step * 🐋 fix(Dockerfile): Possible interference from librechat-data-provider in client build
This commit is contained in:
parent
09cd1a7e74
commit
d0d8e47ec8
1 changed files with 2 additions and 1 deletions
|
@ -13,11 +13,12 @@ RUN npm run build
|
||||||
# React client build
|
# React client build
|
||||||
FROM data-provider-build AS client-build
|
FROM data-provider-build AS client-build
|
||||||
WORKDIR /app/client
|
WORKDIR /app/client
|
||||||
COPY ./client/ ./
|
COPY ./client/package*.json ./
|
||||||
# Copy data-provider to client's node_modules
|
# Copy data-provider to client's node_modules
|
||||||
RUN mkdir -p /app/client/node_modules/librechat-data-provider/
|
RUN mkdir -p /app/client/node_modules/librechat-data-provider/
|
||||||
RUN cp -R /app/packages/data-provider/* /app/client/node_modules/librechat-data-provider/
|
RUN cp -R /app/packages/data-provider/* /app/client/node_modules/librechat-data-provider/
|
||||||
RUN npm install
|
RUN npm install
|
||||||
|
COPY ./client/ ./
|
||||||
ENV NODE_OPTIONS="--max-old-space-size=2048"
|
ENV NODE_OPTIONS="--max-old-space-size=2048"
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue