mirror of
https://github.com/umami-software/umami.git
synced 2025-12-06 01:18:00 +01:00
Run migrations on start
This commit is contained in:
parent
0f32f48c24
commit
9ea175eb3f
10 changed files with 40 additions and 199 deletions
|
|
@ -35,10 +35,14 @@ ENV NEXT_TELEMETRY_DISABLED 1
|
|||
RUN addgroup --system --gid 1001 nodejs
|
||||
RUN adduser --system --uid 1001 nextjs
|
||||
|
||||
RUN yarn global add prisma
|
||||
|
||||
# You only need to copy next.config.js if you are NOT using the default configuration
|
||||
COPY --from=builder /app/next.config.js ./
|
||||
COPY --from=builder /app/public ./public
|
||||
COPY --from=builder /app/package.json ./package.json
|
||||
COPY --from=builder /app/prisma/schema.prisma ./prisma/schema.prisma
|
||||
COPY --from=builder /app/prisma/migrations ./prisma/migrations
|
||||
|
||||
# Automatically leverage output traces to reduce image size
|
||||
# https://nextjs.org/docs/advanced-features/output-file-tracing
|
||||
|
|
@ -51,4 +55,4 @@ EXPOSE 3000
|
|||
|
||||
ENV PORT 3000
|
||||
|
||||
CMD ["node", "server.js"]
|
||||
CMD ["yarn", "production"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue