diff --git a/scripts/start-with-migrate.js b/scripts/start-with-migrate.js index e10f5fd..89195ed 100644 --- a/scripts/start-with-migrate.js +++ b/scripts/start-with-migrate.js @@ -134,7 +134,17 @@ async function main() { // If baseline fails we continue to migrate deploy, which will surface the real issue. } } - run("node", ["node_modules/prisma/build/index.js", "migrate", "deploy"]); + + const migrateResult = spawnSync( + "node", + ["node_modules/prisma/build/index.js", "migrate", "deploy"], + { stdio: "inherit", env: process.env } + ); + if (migrateResult.status !== 0) { + console.error( + `[startup] prisma migrate deploy failed (exit ${migrateResult.status}). Starting server anyway...` + ); + } } else { console.log("SKIP_PRISMA_MIGRATE=true -> skipping prisma migrate deploy"); }