P
Prisma2mo ago
Yonatan

Prisma migrate deploy fails in GitHub actions

We have an application that uses Prisma for the ORM and migrations Every time we do prisma migrate deploy to our production schema the migrations fail and gives us an error:
Environment variables loaded from .env
Prisma schema loaded from prisma/schema.prisma
Datasource "db": PostgreSQL database "postgres", schema "prod" at "**************************************"

72 migrations found in prisma/migrations

Applying migration `20240520121321_add_active_column_to_profile`
Error: P1017

Server has closed the connection.
Environment variables loaded from .env
Prisma schema loaded from prisma/schema.prisma
Datasource "db": PostgreSQL database "postgres", schema "prod" at "**************************************"

72 migrations found in prisma/migrations

Applying migration `20240520121321_add_active_column_to_profile`
Error: P1017

Server has closed the connection.
It does not happen in schemas in the same database that have less data like "dev" When running locally the prisma migrate deploy (and not from the github actions) sometimes it works but it takes a few tries Moreover, it doesn't only fail but it puts a lock on the database which is not being released and makes the application go down Also in general migrations are taking very very long We are using RDS Aurora PostgreSQL as out database, thanks in advance Prisma version - 5.13.0
0 Replies
No replies yetBe the first to reply to this messageJoin