Fix shared design-token Docker build
This commit is contained in:
1 parent
04791770de
commit
88d1f77d30
5 files changed
+17
-4
No files matched your search
+10
-3
@@ -1,9 +1,11 @@
|
||||
FROM node:22-alpine AS frontend-builder
|
||||
WORKDIR /frontend
|
||||
COPY frontend/package*.json ./
|
||||
COPY shared/packages/design-tokens /shared/packages/design-tokens
|
||||
COPY shared/packages/web-ui /shared/packages/web-ui
|
||||
RUN npm install --prefix /shared/packages/web-ui --no-package-lock --ignore-scripts --no-audit --no-fund --omit=dev
|
||||
COPY shared/package.json shared/package-lock.json /shared/
|
||||
COPY shared/packages/design-tokens/package.json /shared/packages/design-tokens/
|
||||
COPY shared/packages/node-backend/package.json /shared/packages/node-backend/
|
||||
COPY shared/packages/web-ui/package.json /shared/packages/web-ui/
|
||||
RUN npm ci --prefix /shared --ignore-scripts --no-audit --no-fund --omit=dev
|
||||
RUN --mount=type=cache,target=/root/.npm \
|
||||
for attempt in 1 2 3 4 5; do \
|
||||
npm ci && break; \
|
||||
@@ -12,7 +14,12 @@ RUN --mount=type=cache,target=/root/.npm \
|
||||
echo "Gitea npm install failed (attempt ${attempt}/5); retrying in ${delay}s..." >&2; \
|
||||
sleep "$delay"; \
|
||||
done
|
||||
COPY shared/packages/design-tokens /shared/packages/design-tokens
|
||||
COPY shared/packages/node-backend /shared/packages/node-backend
|
||||
COPY shared/packages/web-ui /shared/packages/web-ui
|
||||
COPY frontend/ ./
|
||||
RUN rm -rf /frontend/node_modules/@gabriel20xx/web-ui && \
|
||||
ln -s /shared/packages/web-ui /frontend/node_modules/@gabriel20xx/web-ui
|
||||
RUN npm run build
|
||||
|
||||
FROM golang:1.26-alpine AS builder
|
||||
|
||||
Reference in new issue
Block a user