Llabe
Llabe•9mo ago

Deploying Next 14 + Convex in Vercel

When I first try deploying my application, it throw an error because it was missing the CONVEX_DEPLOY_KEY. So I added it and reployed, but now it's saying: Detected a non-production build environment and "CONVEX_DEPLOY_KEY" for a production Convex deployment. If someone had this issue, I would love to hear how you fix it 😄
8 Replies
ballingt
ballingt•9mo ago
Where are you building this app? This is a warning you can ignore if you need to, but often it means something about your setup is surprising Is this building in GitHub CI, on Vercel, on your local machine, etc?
Llabe
LlabeOP•9mo ago
I am doing the deployment in vercel importing everything from my github
ballingt
ballingt•9mo ago
And what version if Convex are you using?
Llabe
LlabeOP•9mo ago
I beive the last one, but let me check "convex": "^1.10.0", I could try with netlify instead, to see if it works there
ballingt
ballingt•9mo ago
Vercel is the mist common environment folks use, it should be fine.
Llabe
LlabeOP•9mo ago
Okey, i'll try again then
ballingt
ballingt•9mo ago
You can add --check-build-environment=false to your deploy command to ignore this warning, (note this is not recommended) but let's try to figure it out first Is this a Vercel preview deployment? @Llabe you don't want to run a convex deploy command for a vercel preview deploy because that would change the backend if your production deployment.
ballingt
ballingt•9mo ago
Preview Deployments | Convex Developer Hub
Use Convex with your hosting provider's preview deployments

Did you find this page helpful?