Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker image optimizations #31

Open
pmelab opened this issue Apr 8, 2023 · 0 comments
Open

Docker image optimizations #31

pmelab opened this issue Apr 8, 2023 · 0 comments

Comments

@pmelab
Copy link
Contributor

pmelab commented Apr 8, 2023

Installs don't use --no-optional due to required optional binaries by swc.

This should go back to pnpm fetch --dev && pnpm fetch --prod:

RUN --mount=type=cache,target=/tmp/cache pnpm fetch

Here we need to re-add --no-optional:

RUN --mount=type=cache,target=/tmp/cache pnpm install --frozen-lockfile --prefer-offline && \
rm -rf node_modules apps/*/node_modules packages/*/node_modules packages/*/*/node_modules

The issue is similar to this one: https://nextjs.org/docs/messages/failed-loading-swc

Maybe we can manually install the platform binaries for swc? Otherwise we might have to move away from swc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant