You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The command npx prisma generate failes with v7 with the error message that no DATABASE_URL is set.
In v6 the command works even when there is no database url provided.
This is required when generating the client in the Dockerfile and the database url is only provided when running the docker image. (and not compiling it)
Expected vs. Actual Behavior
The generation of the client should work even if no database url is provided.
Frequency
Consistently reproducible
Does this occur in development or production?
Both development and production
Is this a regression?
Yes, in Prisma v6 this works.
Workaround
Setting ENV DATABASE_URL=ignore in the Dockerfile before generating the client fixes the issue.
When running the image and setting the correct DATABASE_URL the correct connection is used.
Activity
Lure5134 commentedon Nov 25, 2025
Duplicate: #28590