H
Hono2w ago
lassiter

hono + vercel + monorepo + turborepo -- what is the trick?

is there a trick to getting vercel.json to be used with turborepo? I have pnpm managing my monorepo but it seems like my apps/heimdall/vercel.json keeps getting ignored
{
"$schema": "https://openapi.vercel.sh/vercel.json",
"framework": "hono",
"buildCommand": "echo \"build command used\" && cd ../../ && turbo build --filter=heimdall...",
"installCommand": "echo \"install command used\" && cd ../../ && pnpm install",
"outputDirectory": "../../.vercel/output"
}
{
"$schema": "https://openapi.vercel.sh/vercel.json",
"framework": "hono",
"buildCommand": "echo \"build command used\" && cd ../../ && turbo build --filter=heimdall...",
"installCommand": "echo \"install command used\" && cd ../../ && pnpm install",
"outputDirectory": "../../.vercel/output"
}
I just see it run vercel build and not pick up turborepo or my app. If I deploy directly from local its fine but in the vercel ci the build fails because of typescript dependencies not being found because the project is not built correctly. I tried using the config but seems to get ignored...
1 Reply
lassiter
lassiterOP2w ago
Vercel Community
buildCommand Ignored in pnpm Monorepo with Turborepo
TL;DR Problem: Vercel completely ignores custom buildCommand in vercel.json for pnpm monorepo deployment, causing TypeScript compilation to fail with TS2307 “Cannot find module” errors for workspace dependencies. Evidence: Debug echo statements in buildCommand don’t appear in build logs, proving Vercel runs default build proce...

Did you find this page helpful?