Skip to content

Commit

Permalink
Merge pull request #1812 from qdraw/feature/202411_docker
Browse files Browse the repository at this point in the history
Docker upgrade node version && remove node_modules after build
  • Loading branch information
qdraw authored Nov 11, 2024
2 parents aae68ae + bd7b098 commit 88fb0c6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion starsky/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

# Stage 1 Front-end
# # docker buildx imagetools inspect node:18-alpine
FROM --platform=$BUILDPLATFORM node:18-alpine AS react-build
FROM --platform=$BUILDPLATFORM node:20-alpine AS react-build
ARG TARGETPLATFORM
ARG BUILDPLATFORM

Expand All @@ -27,6 +27,7 @@ RUN for i in 1 2 3; do \
npm ci --legacy-peer-deps --prefer-offline --no-audit --no-fund --ignore-scripts && break || sleep 15; \
done && \
npm run build && \
rm -rf node_modules && \
echo "react done"

# no alpine build since there is no support for multi-arch
Expand Down

0 comments on commit 88fb0c6

Please sign in to comment.