Skip to content

Connection url is empty #738

@mmikhan

Description

@mmikhan

Describe the bug
Running bun run migrate command in a fresh project shows the following error even though DATABASE_URL is set to packages/database/.env as expected as mentioned in the docs.

❯ bun run migrate
$ cd packages/database && bunx prisma format && bunx prisma generate && bunx prisma migrate dev
Loaded Prisma config from prisma.config.ts.

Prisma schema loaded from prisma/schema.prisma.
Formatted prisma/schema.prisma in 9ms 🚀
Loaded Prisma config from prisma.config.ts.

Prisma schema loaded from prisma/schema.prisma.

✔ Generated Prisma Client (7.4.2) to ./generated in 24ms

Loaded Prisma config from prisma.config.ts.

Prisma schema loaded from prisma/schema.prisma.
Datasource "db": PostgreSQL database

Error: Connection url is empty. See https://pris.ly/d/config-url
error: script "migrate" exited with code 1

next-forge version
I am using version 6.0.2

To Reproduce
Steps to reproduce the behavior:

  1. Init a fresh project bun x next-forge@latest init
  2. Setup the DATABASE_URL in packages/database/.env
  3. Run bun run migrate command

Expected behavior
Migration runs successfully

Screenshots
N/A

Desktop (please complete the following information):

  • OS: MacOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions