fix(agent): replace jsdom with linkedom to fix Docker EISDIR error (#186)

jsdom relies on Node.js-specific APIs that Bun cannot properly resolve
when running a bundled artifact. This caused an EISDIR error in Docker
containers (Bun tried to read the jsdom directory as a file).

Replace jsdom with linkedom, a lightweight pure-JS DOM implementation
that is fully compatible with Bun and @mozilla/readability. Also remove
the --external jsdom build flag since linkedom bundles cleanly.

Closes #181
This commit is contained in:
BBQ
2026-03-04 22:11:08 +08:00
committed by GitHub
parent 9ceabf68c4
commit a8b960db80
5 changed files with 166 additions and 63 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ COPY packages/config/ ./packages/config/
COPY packages/agent/ ./packages/agent/
COPY agent/ ./agent/
RUN cd agent && bun run build --external jsdom
RUN cd agent && bun run build
FROM oven/bun:1-alpine