Nutlope / roomGPT

Upload a photo of your room to generate your dream room with AI.
https://www.roomgpt.io/
MIT License
9.87k stars 1.31k forks source link

Prisma schema having issues on Vercel deployment #48

Closed ex0rcist88 closed 1 year ago

ex0rcist88 commented 1 year ago

Unable to deploy on Vercel

Error: Prisma schema validation - (get-config wasm)

16:15:40.687 | Error code: P1012 16:15:40.688 | error: Environment variable not found: DIRECT_DATABASE_URL. 16:15:40.688 | --> schema.prisma:4 16:15:40.688 | | 16:15:40.688 | 3 | url = env("DATABASE_URL") 16:15:40.688 | 4 | directUrl = env("DIRECT_DATABASE_URL") 16:15:40.689 | | 16:15:40.689 |   16:15:40.689 | Validation Error Count: 1 16:15:40.689 | [Context: getConfig] 16:15:40.689 |   16:15:40.689 | Prisma CLI Version : 4.11.0 16:15:40.754 | Error: Command "npm run build" exited with 1 16:15:40.974 | BUILD_UTILS_SPAWN_1: Command "npm run build" exited with 1

Niuecl commented 1 year ago

I added DIRECT_DATABASE_URL to .env file to fixed this issue. May be it can help you

ex0rcist88 commented 1 year ago

I added it to example.env and appended it as a required env variable in vercel. What is the value though? How does it differ from DATABASE_URL?

jetlej commented 1 year ago

+1

Nutlope commented 1 year ago

Hey all. I've just simplified the repo to remove auth and payments so you can clone and deploy very easily, only with a Replicate environment variable. Try it out and if you still have any problems, please open a new issue and I will take a look!