chore: use explicit prisma-build

This is only used for building on vercel. Since there is no prerun hook to execute migration so we have to do the migration on build time.
This commit is contained in:
Tianzhou Chen
2023-04-25 22:15:02 +08:00
parent 5427a7f4d1
commit 4f02a6f9ad
2 changed files with 2 additions and 3 deletions

View File

@ -15,7 +15,7 @@ WORKDIR /app
COPY --from=deps /app/node_modules ./node_modules
COPY . .
RUN yarn run docker-build
RUN yarn run build
# Production image, copy all the files and run next
FROM base AS runner

View File

@ -7,8 +7,7 @@
"export": "next export",
"start": "next start",
"lint": "next lint",
"vercel-build": "prisma generate && prisma migrate deploy && next build",
"docker-build": "prisma generate && prisma migrate deploy && next build"
"prisma-build": "prisma generate && prisma migrate deploy && next build"
},
"dependencies": {
"@emotion/react": "^11.10.6",