Commit Graph
2 Commits
Author SHA1 Message Date
MythEclipse c22e394f98 fix: bundle @mcpedia/* deps in nix build, fix runtime module resolution
CI / typecheck + tests (push) Canceled after 0s
CI / build + deploy (Nix) — api (push) Canceled after 0s
CI / build + deploy (Nix) — mcp (push) Canceled after 0s
CI / build + deploy (Nix) — worker (push) Canceled after 0s
CI / build + deploy (web) (push) Canceled after 0s
Replace --external approach (which failed because @mcpedia/* workspace
packages couldn't resolve their npm deps like ioredis/bullmq at runtime)
with full bundling. The key fixes:

1. Bundle all code into a single JS file (no --external for @mcpedia/*)
   - This inlines @mcpedia/core, @mcpedia/queue, ioredis, bullmq, etc.
   - Produces ~2.6MB self-contained binary, no node_modules needed

2. Fix .bun cache symlink issues in nix sandbox:
   - After bun install, copy .bun cache with cp -rL to dereference
     relative symlinks that break in nix build sandbox
   - This was the root cause of 'File not found msgpackr-extract' errors

3. Only @mcpedia/config, embeddings, types kept external (lightweight,
   no npm deps) - resolved via packages/ source symlinks at runtime

All 3 services (api, mcp, worker) now build and run successfully in nix store.
Resolves CI failure run 32474463114 ('Cannot find module @mcpedia/core').
2026-08-21 20:36:43 +07:00
asepharyana e01ee22438 fix: nix build with dontFixup, root node_modules copy, web path literal fix
CI / typecheck + tests (push) Canceled after 0s
CI / build + deploy (Nix) — api (push) Canceled after 0s
CI / build + deploy (Nix) — mcp (push) Canceled after 0s
CI / build + deploy (Nix) — worker (push) Canceled after 0s
CI / build + deploy (web) (push) Canceled after 0s
2026-08-21 17:17:39 +07:00