fix: retry full build install in docker
parent
d0474a5e59
commit
34dd56b789
|
|
@ -3,33 +3,33 @@ FROM node:20 AS frontend-builder
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
# Copy package.json for metadata generation
|
# Copy package.json for metadata generation and common dependencies
|
||||||
COPY package.json .
|
COPY package.json .
|
||||||
RUN npm install --ignore-scripts
|
RUN npm install
|
||||||
|
|
||||||
# Build avr8js
|
# Build avr8js
|
||||||
COPY wokwi-libs/avr8js/ wokwi-libs/avr8js/
|
COPY wokwi-libs/avr8js/ wokwi-libs/avr8js/
|
||||||
WORKDIR /app/wokwi-libs/avr8js
|
WORKDIR /app/wokwi-libs/avr8js
|
||||||
RUN npm install --ignore-scripts && npm run build
|
RUN npm install && npm run build
|
||||||
|
|
||||||
# Build rp2040js
|
# Build rp2040js
|
||||||
COPY wokwi-libs/rp2040js/ wokwi-libs/rp2040js/
|
COPY wokwi-libs/rp2040js/ wokwi-libs/rp2040js/
|
||||||
WORKDIR /app/wokwi-libs/rp2040js
|
WORKDIR /app/wokwi-libs/rp2040js
|
||||||
RUN npm install --ignore-scripts && npm run build
|
RUN npm install && npm run build
|
||||||
|
|
||||||
# Build wokwi-elements
|
# Build wokwi-elements
|
||||||
COPY wokwi-libs/wokwi-elements/ wokwi-libs/wokwi-elements/
|
COPY wokwi-libs/wokwi-elements/ wokwi-libs/wokwi-elements/
|
||||||
WORKDIR /app/wokwi-libs/wokwi-elements
|
WORKDIR /app/wokwi-libs/wokwi-elements
|
||||||
RUN npm install --ignore-scripts && npm run build
|
RUN npm install && npm run build
|
||||||
|
|
||||||
# Build frontend and generate metadata
|
# Build frontend and generate metadata
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY frontend/ frontend/
|
COPY frontend/ frontend/
|
||||||
COPY scripts/ scripts/
|
COPY scripts/ scripts/
|
||||||
WORKDIR /app/frontend
|
WORKDIR /app/frontend
|
||||||
# We need tsx available in the path for the metadata script
|
# Explicitly install frontend dependencies
|
||||||
RUN npm install --ignore-scripts
|
RUN npm install
|
||||||
# The metadata script uses eval so we must ensure it can run
|
# Now run the build which includes metadata generation
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue