Chromium in Nix or Alpine image?

Hello everyone,

I am encountering an issue while using the nixos/nix Docker base image to run JavaScript tests in a CI pipeline. The environment is relatively simple, requiring only nodejs_22, yarn, and chromium.

In our CI configuration, we use the following setup:

  nix profile add nixpkgs#nodejs_22 nixpkgs#yarn nixpkgs#chromium
  export CHROME_BIN=$(which chromium)
  yarn install --frozen-lockfile
  yarn ng test --watch=false --browsers=ChromeHeadlessCI

The application contains roughly 1800 tests. This setup almost works; the tests run correctly until they reach approximately the 1200th test, at which point the build consistently fails with a disconnection error.

Here are the relevant logs:

22 01 2026 16:07:53.730:DEBUG [middleware:source-files]: Requesting /assets/icons/sprites/eui.svg
22 01 2026 16:07:53.730:DEBUG [middleware:source-files]: Fetching /assets/icons/sprites/eui.svg
22 01 2026 16:07:53.731:WARN [web-server]: 404: /_karma_webpack_/assets/icons/sprites/eui.svg
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 SUCCESS (0 secs / 30.588 secs)
          OK: should handle SVG icons
22 01 2026 16:07:53.770:DEBUG [middleware:source-files]: Requesting /assets/icons/sprites/eui.svg
22 01 2026 16:07:53.770:DEBUG [middleware:source-files]: Fetching /assets/icons/sprites/eui.svg
22 01 2026 16:07:53.771:WARN [web-server]: 404: /_karma_webpack_/assets/icons/sprites/eui.svg
22 01 2026 16:07:54.194:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected during run, waiting 60000ms for reconnecting.
22 01 2026 16:07:54.195:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: EXECUTING -> EXECUTING_DISCONNECTED
22 01 2026 16:08:54.195:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (0 times) reconnect failed before timeout of 60000ms (transport close)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected reconnect failed before timeout of 60000ms (transport close)
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (2 mins 0.76 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected reconnect failed before timeout of 60000ms (transport close)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected reconnect failed before timeout of 60000ms (transport close)
22 01 2026 16:08:54.197:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: EXECUTING_DISCONNECTED -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (2 mins 0.76 secs / 30.588 secs)
22 01 2026 16:08:54.198:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (1 of 6 attempts)
22 01 2026 16:08:54.200:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:08:54.236:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:08:54.237:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:08:54.305:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:08:54.305:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:08:54.306:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:08:54.306:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:08:54.306:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:08:54.859:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:08:54.889:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:08:54.981:DEBUG [karma-server]: A browser has connected on socket OIsbXnjYLdlr62rfAAAD
22 01 2026 16:08:54.985:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=w6tr9BCMKzTD1plJAAAC
22 01 2026 16:08:54.989:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:08:55.004:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket OIsbXnjYLdlr62rfAAAD with id 22076296.
22 01 2026 16:08:55.004:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:08:55.005:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:08:55.005:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 130.126 secs
22 01 2026 16:08:55.006:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:10:55.007:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (1 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (4 mins 1.571 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:10:55.007:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (4 mins 1.571 secs / 30.588 secs)
22 01 2026 16:10:55.007:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (2 of 6 attempts)
22 01 2026 16:10:55.007:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:10:55.049:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:10:55.054:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:10:55.099:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:10:55.099:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:10:55.099:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:10:55.099:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:10:55.099:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:10:55.595:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:10:55.617:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:10:55.690:DEBUG [karma-server]: A browser has connected on socket aJVSc32tmrBMTgUVAAAF
22 01 2026 16:10:55.694:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=EjIWqzNY0EwMP7szAAAE
22 01 2026 16:10:55.699:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:10:55.711:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket aJVSc32tmrBMTgUVAAAF with id 22076296.
22 01 2026 16:10:55.711:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:10:55.713:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:10:55.713:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 250.834 secs
22 01 2026 16:10:55.714:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:12:55.716:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (2 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (6 mins 2.281 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:12:55.716:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (6 mins 2.281 secs / 30.588 secs)
22 01 2026 16:12:55.717:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (3 of 6 attempts)
22 01 2026 16:12:55.717:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:12:55.755:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:12:55.755:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:12:55.840:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:12:55.840:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:12:55.840:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:12:55.840:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:12:55.840:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:12:56.276:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:12:56.306:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:12:56.383:DEBUG [karma-server]: A browser has connected on socket H101M21GDz4g7BD9AAAH
22 01 2026 16:12:56.399:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket H101M21GDz4g7BD9AAAH with id 22076296.
22 01 2026 16:12:56.400:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:12:56.400:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:12:56.401:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 371.522 secs
22 01 2026 16:12:56.401:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:12:56.409:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=UEk-aIHX1PrVo_vnAAAG
22 01 2026 16:12:56.417:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:14:56.402:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (3 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (8 mins 2.967 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:14:56.403:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (8 mins 2.967 secs / 30.588 secs)
22 01 2026 16:14:56.403:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (4 of 6 attempts)
22 01 2026 16:14:56.403:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:14:56.451:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:14:56.452:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:14:56.485:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:14:56.485:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:14:56.485:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:14:56.486:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:14:56.486:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:14:56.977:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:14:56.998:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:14:57.078:DEBUG [karma-server]: A browser has connected on socket PBgnALWLowT8uWhAAAAJ
22 01 2026 16:14:57.083:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=ppJEMIpM7_L13Qm9AAAI
22 01 2026 16:14:57.094:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket PBgnALWLowT8uWhAAAAJ with id 22076296.
22 01 2026 16:14:57.095:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:14:57.096:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:14:57.096:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 492.217 secs
22 01 2026 16:14:57.096:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:14:57.110:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:16:57.097:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (4 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (10 mins 3.661 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:16:57.098:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (10 mins 3.661 secs / 30.588 secs)
22 01 2026 16:16:57.098:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (5 of 6 attempts)
22 01 2026 16:16:57.098:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:16:57.137:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:16:57.138:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:16:57.176:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:16:57.176:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:16:57.176:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:16:57.176:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:16:57.177:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:16:57.685:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:16:57.716:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:16:57.793:DEBUG [karma-server]: A browser has connected on socket jbdv5cYYXYa8OdbGAAAL
22 01 2026 16:16:57.801:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=eo9fSovJDyLDSBi3AAAK
22 01 2026 16:16:57.805:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:16:57.810:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket jbdv5cYYXYa8OdbGAAAL with id 22076296.
22 01 2026 16:16:57.811:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:16:57.812:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:16:57.812:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 612.933 secs
22 01 2026 16:16:57.812:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:18:57.814:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (5 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (12 mins 4.379 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:18:57.814:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (12 mins 4.379 secs / 30.588 secs)
22 01 2026 16:18:57.814:INFO [karma-server]: Restarting Chrome Headless 144.0.0.0 (Linux 0.0.0) (6 of 6 attempts)
22 01 2026 16:18:57.815:DEBUG [launcher]: CAPTURED -> RESTARTING
22 01 2026 16:18:57.853:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:18:57.853:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:18:57.892:DEBUG [launcher]: RESTARTING -> FINISHED
22 01 2026 16:18:57.892:DEBUG [launcher]: Restarting ChromeHeadless
22 01 2026 16:18:57.892:DEBUG [launcher]: FINISHED -> BEING_CAPTURED
22 01 2026 16:18:57.892:DEBUG [temp-dir]: Creating temp dir at /tmp/karma-22076296
22 01 2026 16:18:57.892:DEBUG [launcher]: /root/.nix-profile/bin/chromium --user-data-dir=/tmp/karma-22076296 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-background-timer-throttling --disable-renderer-backgrounding --disable-device-discovery-notifications --no-sandbox --disable-gpu http://localhost:9876/?id=22076296 --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222
22 01 2026 16:18:58.370:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/client.html
22 01 2026 16:18:58.398:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/karma.js
22 01 2026 16:18:58.470:DEBUG [karma-server]: A browser has connected on socket 7I0i_4SK4y3y87DFAAAN
22 01 2026 16:18:58.475:DEBUG [web-server]: upgrade /socket.io/?EIO=4&transport=websocket&sid=l3rC1ccBaGb4JZ-GAAAM
22 01 2026 16:18:58.479:DEBUG [web-server]: serving (cached): /builds/[redacted]/[redacted]/node_modules/karma/static/favicon.ico
22 01 2026 16:18:58.486:INFO [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected browser returned on socket 7I0i_4SK4y3y87DFAAAN with id 22076296.
22 01 2026 16:18:58.486:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> CONNECTED
22 01 2026 16:18:58.487:DEBUG [launcher]: BEING_CAPTURED -> CAPTURED
22 01 2026 16:18:58.487:DEBUG [launcher]: ChromeHeadless (id 22076296) captured in 733.608 secs
22 01 2026 16:18:58.487:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONNECTED -> CONFIGURING
22 01 2026 16:20:58.487:WARN [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: Disconnected (6 times) , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (14 mins 5.052 secs / 30.588 secs)
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
Chrome Headless 144.0.0.0 (Linux 0.0.0) ERROR
  Disconnected , because no message in 120000 ms.
22 01 2026 16:20:58.487:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: CONFIGURING -> DISCONNECTED
Chrome Headless 144.0.0.0 (Linux 0.0.0): Executed 1200 of 1786 DISCONNECTED (14 mins 5.052 secs / 30.588 secs)
22 01 2026 16:20:58.488:DEBUG [launcher]: CAPTURED -> BEING_KILLED
22 01 2026 16:20:58.488:DEBUG [launcher]: BEING_KILLED -> BEING_FORCE_KILLED
22 01 2026 16:20:58.488:DEBUG [Chrome Headless 144.0.0.0 (Linux 0.0.0)]: DISCONNECTED -> DISCONNECTED
22 01 2026 16:20:58.495:DEBUG [karma-server]: Run complete, exiting.
22 01 2026 16:20:58.495:DEBUG [launcher]: Disconnecting all browsers
22 01 2026 16:20:58.496:DEBUG [launcher]: BEING_FORCE_KILLED -> BEING_FORCE_KILLED
✔ Browser application bundle generation complete.
22 01 2026 16:20:58.500:DEBUG [proxy]: Destroying proxy agents
=============================== Coverage summary ===============================
Statements   : Unknown% ( 0/0 )
Branches     : Unknown% ( 0/0 )
Functions    : Unknown% ( 0/0 )
Lines        : Unknown% ( 0/0 )
================================================================================
22 01 2026 16:20:58.515:DEBUG [coverage]: Writing coverage to /builds/[redacted]/[redacted]/coverage
22 01 2026 16:20:58.550:DEBUG [launcher]: Process ChromeHeadless exited with code 0 and signal null
22 01 2026 16:20:58.550:DEBUG [temp-dir]: Cleaning temp dir /tmp/karma-22076296
22 01 2026 16:20:58.623:DEBUG [launcher]: Finished all browsers
22 01 2026 16:20:58.623:DEBUG [launcher]: BEING_FORCE_KILLED -> FINISHED
22 01 2026 16:20:58.623:DEBUG [launcher]: FINISHED -> FINISHED
22 01 2026 16:20:58.626:DEBUG [karma-server]: Received stop event, exiting.
22 01 2026 16:20:58.626:DEBUG [launcher]: Disconnecting all browsers
22 01 2026 16:20:58.626:DEBUG [launcher]: FINISHED -> BEING_FORCE_KILLED
✔ Browser application bundle generation complete.
22 01 2026 16:20:58.626:DEBUG [proxy]: Destroying proxy agents
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 1

I have attempted to increase the Karma timeout values and the browserDisconnectTimeout, but this has not resolved the issue.

To my immense frustration, when I switched to the node:22-alpine image instead of nixos/nix, the tests succeeded immediately without any further changes or timeout adjustments.

I would really like to understand the root cause of this discrepancy. Has anyone experienced similar stability issues with Chromium when running inside the Nix Docker image?

How would you recommend I go about debugging this? For example, could it be related to how the Nix environment handles /dev/shm or memory allocation compared to Alpine?

Any insights would be greatly appreciated.