Monorepo Builds keep using npm instead of bun

As title says, I keep having the issue that the automatic builds correctly identify bun and it's version but proceed trying to install with npm. Can I somehow force Cloudflare Build to use bun over npm?
7 Replies
RiskyMH
RiskyMH2mo ago
is there a chance you are using the new text lockfile format of bun.lock or do you have your bun.lockb file in the monorepo package/app and not root?
makisuo
makisuoOP2mo ago
issue is in most workflows I use the package directory as the root directory, meaning the lockfile isnt found by the CF CI defaulting to npm. I would just really like to force it to use bun rather than switching the app root.
RiskyMH
RiskyMH2mo ago
Ah i see, this is where vercel makes it easier with custom install script
makisuo
makisuoOP2mo ago
Yeah don’t really understand though why this isn’t an option here doesn’t seem too much 🥲
iRazvan2745
iRazvan27452mo ago
same issue happening to me @Makisuo did you find a fix? ohh vercel how did you do it tho?
i40west
i40west2mo ago
You can set an environment variable SKIP_DEPENDENCY_INSTALL (to any value) and then put whatever installation you need in your build command.
Barrel Of Lube
this worked

Did you find this page helpful?