Skip to content

Commit

Permalink
switch to clean-modules
Browse files Browse the repository at this point in the history
Signed-off-by: Zoey <[email protected]>
  • Loading branch information
Zoey2936 authored Apr 19, 2024
1 parent 03e5dc5 commit e5070f5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ ARG NODE_ENV=production \
WORKDIR /build/frontend
RUN apk upgrade --no-cache -a && \
apk add --no-cache ca-certificates nodejs yarn git python3 build-base && \
yarn global add clean-modules && \
yarn --no-lockfile install && \
clean-modules --yes && \
yarn --no-lockfile build && \
yarn cache clean --all
COPY darkmode.css /build/frontend/dist/css/darkmode.css
Expand All @@ -23,13 +25,13 @@ ARG NODE_ENV=production \
WORKDIR /build/backend
RUN apk upgrade --no-cache -a && \
apk add --no-cache ca-certificates nodejs-current yarn && \
wget -q https://gobinaries.com/tj/node-prune -O - | sh && \
yarn global add clean-modules && \
if [ "$TARGETARCH" = "amd64" ]; then \
npm_config_target_platform=linux npm_config_target_arch=x64 yarn install --no-lockfile; \
elif [ "$TARGETARCH" = "arm64" ]; then \
npm_config_target_platform=linux npm_config_target_arch=arm64 yarn install --no-lockfile; \
fi && \
node-prune && \
clean-modules --yes && \
yarn cache clean --all


Expand Down

0 comments on commit e5070f5

Please sign in to comment.