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

error while building inside docker #35

Open
iraizo opened this issue Oct 21, 2023 · 2 comments
Open

error while building inside docker #35

iraizo opened this issue Oct 21, 2023 · 2 comments

Comments

@iraizo
Copy link

iraizo commented Oct 21, 2023

Hello, I've tried to build my sveltekit project inside a dockerfile but stumbled onto an unimplemented function (is what it seems like?)

 > [5/5] RUN bun run build:
2.815 > Using svelte-adapter-bun
2.828 error during build:
2.828 TypeError: undefined is not a function (near '...zlib.createBrotliCompress...')
2.828     at <anonymous> (/home/bun/app/node_modules/svelte-adapter-bun/index.js:144:18)
2.828     at compress_file (/home/bun/app/node_modules/svelte-adapter-bun/index.js:142:14)
2.828     at <anonymous> (/home/bun/app/node_modules/svelte-adapter-bun/index.js:133:2)
2.828     at map (:1:11)
2.828     at <anonymous> (/home/bun/app/node_modules/svelte-adapter-bun/index.js:133:2)
2.828     at processTicksAndRejections (:61:39)
2.852 error: script "build" exited with code 1 (SIGHUP)

This only happens when toggling the brotli precompression on, (for some reason it works on my local machine?) It seems like the Bun documentation also states that zlib.createBrotliCompress is unimplemented, I've also searched for the function inside the source code of Bun itself and only found type definitions for it.

@Baehn
Copy link

Baehn commented Nov 9, 2023

same problem here, installing nodejs in my container solved it which is probably also explaining why it is working on your local machine

@iraizo
Copy link
Author

iraizo commented Nov 9, 2023

same problem here, installing nodejs in my container solved it which is probably also explaining why it is working on your local machine

I just fixed it temporarily by disabling brotli

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

2 participants