do migrate on start instead

This commit is contained in:
Carl-Gerhard Lindesvärd
2023-10-12 08:15:23 +02:00
parent fe7e2325aa
commit 9ce18c480d
2 changed files with 2 additions and 2 deletions

View File

@@ -21,7 +21,7 @@ RUN bun install
COPY . . COPY . .
WORKDIR /app/apps/backend WORKDIR /app/apps/backend
RUN bunx prisma generate RUN bunx prisma generate
RUN bunx prisma migrate deploy # RUN bunx prisma migrate deploy
WORKDIR /app/apps/backend WORKDIR /app/apps/backend
EXPOSE ${PORT} EXPOSE ${PORT}
CMD ["bun", "start"] CMD ["bun", "start"]

View File

@@ -4,7 +4,7 @@
"description": "", "description": "",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {
"start": "bun src/app.ts", "start": "bunx prisma migrate deploy && bun src/app.ts",
"dev": "bun --watch src/app.ts", "dev": "bun --watch src/app.ts",
"codegen": "bunx prisma generate" "codegen": "bunx prisma generate"
}, },