You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Docker: every dist/cli/agentdb-cli.js reference is wrong (tsconfig emits dist/src/cli/) — breaks the production image CMD and 3 build stages #25
Every Docker reference to the CLI uses dist/cli/agentdb-cli.js, but the build never emits that path. tsconfig.json sets rootDir: ".", so everything under src/ lands in dist/src/. The package's own manifest already agrees:
This is masked by the healthcheck, which is node -e "process.exit(0)" — it passes regardless of whether the CLI resolves, so the container reports healthy while its CMD is broken.
Reproduction
At a478ab3 (3.0.0-alpha.14):
$ npx tsc # emits
$ ls dist/cli/agentdb-cli.js
ls: cannot access 'dist/cli/agentdb-cli.js': No such file or directory
$ ls dist/src/cli/agentdb-cli.js
dist/src/cli/agentdb-cli.js
Verified against both the committed tsconfig.json and a narrowed variant (include: ["src/**/*", "simulation/**/*"]) — dist/cli/ is absent either way, so it isn't a side effect of which files are included. rootDir: "." is what decides it.
In Docker, --target cli-test fails at:
#16 Error: Cannot find module '/app/dist/cli/agentdb-cli.js'
#16 ERROR: process "/bin/sh -c node dist/cli/agentdb-cli.js --version && ..." did not complete successfully
docker/validation/02-test-cli-commands.sh:14 guards on if [ -f "./dist/cli/agentdb-cli.js" ], so it takes the "CLI binary not found" branch rather than surfacing the path mismatch.
Suggested fix
Either point the Docker assets at what the build produces:
or, if dist/cli/… is the intended layout, set rootDir: "./src" in tsconfig.json and update main/bin accordingly. The first is the smaller change and matches the existing bin field.
Context
Found downstream in vidaunited/agentic-flow, which vendors this repo as a submodule. Our CI had never reached these stages before — an earlier stage ran the full vitest suite and exhausted the job timeout, so the build never got far enough to execute the CLI checks. Once that stage was removed the build completed in ~3 minutes and surfaced this immediately.
Happy to send a PR if the preferred direction is confirmed.
Activity
Merge pull request #16 from vidaunited/docs/link-upstream-cli-path-issue