PNPM Monorepo on cloudflare pages
hello, i have a pnpm monorepo using lerna, i would like to deploy one of the apps to cloudflare pages from my monorepo
heres my build configuration
the issue is that i cannot cd into the correct directory and its running the
npx @cloudflare/next-on-pages@1
at root directory and build is failing for the same reason3 Replies
btw if i set the root directory as
apps/cdn
then it simply would fail since pnpm would not find any workspace to install local workspace depsHave you tried using a package.json script to run
npx @cloudflare/next-on-pages
instead. For instance, you could have a script in your app's package.json called pages:build
and your build command on Pages could be pnpm run pages:build
, or using the correct syntax to run a specific package's scripts.i will try that when i push new commit into github, thanks
can't i just use wrangler to deploy .vercel directory?
nvm its working now