Environment variable not found: POSTGRES_PRISMA_UR
masapasa opened this issue · comments
npx prisma db push
Prisma schema loaded from prisma/schema.prisma
Datasource "db": PostgreSQL database
Error: Prisma schema validation - (get-config wasm)
Error code: P1012
error: Environment variable not found: POSTGRES_PRISMA_URL.
--> schema.prisma:11
|
10 | provider = "postgresql"
11 | url = env("POSTGRES_PRISMA_URL") // uses connection pooling
|
Validation Error Count: 1
[Context: getConfig].
I used npx vercel env pull .env to pull and also set export POSTGRES_URL_NON_POOLING=
Can you please suggest @steven-tey ?
Definitely an issue with how this is configured. Prisma doesn't use the local environment variables without some hacking.
Just create a .env
file and symlink it to your .env.local
file. Like so:
ln -s .env.local .env