oven-sh / bun

Incredibly fast JavaScript runtime, bundler, test runner, and package manager – all in one
https://bun.sh
Other
74.24k stars 2.77k forks source link

Crash on oven/bun:alpine #14931

Closed spanwair closed 1 week ago

spanwair commented 1 week ago

How can we reproduce the crash?

error:

smalljobs-server-1      | Bun v1.1.33 (247456b6) Linux x64 (baseline)
smalljobs-server-1      | Linux Kernel v6.1.0 | glibc v2.34
smalljobs-server-1      | CPU: sse42 popcnt
smalljobs-server-1      | Args: "bun" "run" "dist/index.js"
smalljobs-server-1      | Features: Bun.stdin http_server https_server jsc no_avx2 no_avx spawn tsconfig tsconfig_paths
smalljobs-server-1      | Builtins: "bun:main" "node:assert" "node:async_hooks" "node:buffer" "node:child_process" "node:crypto" "node:events" "node:fs" "node:fs/promises" "node:http" "node:https" "node:module" "node:net" "node:os" "node:path" "node:querystring" "node:stream" "node:string_decoder" "node:tls" "node:tty" "node:url" "node:util" "node:util/types" "node:zlib" "node:punycode"
smalljobs-server-1      | Elapsed: 607ms | User: 391ms | Sys: 100ms
smalljobs-server-1      | RSS: 1.07GB | Peak: 0.15GB | Commit: 1.07GB | Faults: 424
smalljobs-server-1      |
smalljobs-server-1      | CPU lacks AVX support. Please consider upgrading to a newer CPU.
smalljobs-server-1      | panic(main thread): Segmentation fault at address 0x4A0D0
smalljobs-server-1      | oh no: Bun has crashed. This indicates a bug in Bun, not your code.

docker-compose.yml command:

command: >
      sh -c "
        apk add --no-cache nodejs npm &&
        npm install -g yarn &&
        cd /home/bun/app/storefront && 
        yarn --trace-deprecation install && 
        yarn build && 
        cd /home/bun/app/server &&
        bun run zmodel:generate &&
        ls -a &&
        ./start-pm2-server.sh
      "

image: "oven/bun:alpine"

Docker version 27.3.1, build ce12230

working solution, but this do not build me FE for SSR:

image: "oven/bun"
command: "sh -c ./start-pm2-server.sh"

Relevant log output

No response

Stack Trace (bun.report)

Bun v1.1.33 (247456b) on linux x86_64_baseline [RunAsNodeCommand]

Segmentation fault at address 0x0004A0D0

Features: Bun.stdin, dotenv, jsc, spawn, tsconfig, tsconfig_paths, tsconfig_paths

Sentry Issue: BUN-7G

Jarred-Sumner commented 1 week ago

Note to self: add napi, node-v8, and dlopen to features list

nektro commented 1 week ago

Duplicate of https://github.com/oven-sh/bun/issues/12905