Hello, I'm trying to create a Docker image for an Astro SSR application.
Astro version: latest v4
Docker image base: node:22-alpine
I add the system packages
RUN apk add build-base python3 py3-pip
to the Alpine image to compile some native modules.
The app compiles and starts on the host system without any problems.
However, I always get the following error message from the build process in the Docker image after the build process has been successfully completed:
32.84 11:09:49 [vite] ✓ built in 4.36s
33.08 The requested module '@oslojs/encoding' does not provide an export named 'decodeBase64'
33.08 Stack trace:
33.08 at ModuleJob._instantiate (node:internal/modules/esm/module_job:171:21)
33.08 at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:483:26)
33.08 at async generatePages (file:///app/node_modules/astro/dist/core/build/generate.js:42:16)
33.08 at async AstroBuilder.build (file:///app/node_modules/astro/dist/core/build/index.js:149:5)
33.08 at async build (file:///app/node_modules/astro/dist/core/build/index.js:51:3)
33.08 at async runCommand (file:///app/node_modules/astro/dist/cli/index.js:147:7)
Do you have any idea what the problem could be?