mirror of
https://github.com/DefectingCat/DefectingCat.github.io
synced 2025-07-15 16:51:37 +00:00
Add prisma in docker
* update schema
This commit is contained in:
@ -22,6 +22,7 @@ RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories
|
||||
&& apk update --no-cache \
|
||||
&& apk upgrade --no-cache \
|
||||
&& yarn config set registry https://registry.npm.taobao.org \
|
||||
&& npx prisma generate \
|
||||
&& yarn build && yarn install --production --ignore-scripts --prefer-offline
|
||||
|
||||
# Production image, copy all the files and run next
|
||||
@ -34,6 +35,7 @@ RUN addgroup -g 1001 -S nodejs
|
||||
RUN adduser -S nextjs -u 1001
|
||||
|
||||
# You only need to copy next.config.js if you are NOT using the default configuration
|
||||
COPY --from=builder /app/.env ./
|
||||
COPY --from=builder /app/next.config.js ./
|
||||
COPY --from=builder /app/public ./public
|
||||
COPY --from=builder --chown=nextjs:nodejs /app/.next ./.next
|
||||
|
@ -23,5 +23,6 @@ model Tweets {
|
||||
content String
|
||||
Users Users? @relation(fields: [usersId], references: [id])
|
||||
usersId String?
|
||||
createAt DateTime
|
||||
createAt DateTime @default(now())
|
||||
updateAt DateTime @default(now())
|
||||
}
|
||||
|
Reference in New Issue
Block a user