From 7c0b3bc848e3cf2709c5905d060b499e8e623e58 Mon Sep 17 00:00:00 2001 From: Julien Froidefond Date: Tue, 16 Dec 2025 17:01:53 +0100 Subject: [PATCH] Add database migration command to entrypoint script: Include 'pnpm dlx prisma db push' to ensure database schema is updated during container startup, enhancing deployment reliability. --- Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Dockerfile b/Dockerfile index 27f658c..1f23be2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -67,6 +67,7 @@ RUN echo '#!/bin/sh' > /app/entrypoint.sh && \ echo 'mkdir -p /app/public/uploads' >> /app/entrypoint.sh && \ echo 'mkdir -p /app/public/uploads/backgrounds' >> /app/entrypoint.sh && \ echo 'pnpm dlx prisma migrate deploy || true' >> /app/entrypoint.sh && \ + echo 'pnpm dlx prisma db push || true' >> /app/entrypoint.sh && \ echo 'exec pnpm start' >> /app/entrypoint.sh && \ chmod +x /app/entrypoint.sh && \ chown nextjs:nodejs /app/entrypoint.sh