I am using prisma, postgres, docker, kubernets.
npx prisma migrate dev working.
and npx prisma generate produce below output:
✔ Generated Prisma Client (2.23.0) to ./node_modules/@prisma/client in 68ms
You can now start using Prisma Client in your code. Reference: https://pris.ly/d/client
import { PrismaClient } from '@prisma/client'
const prisma = new PrismaClient()
but when I tried to use in my route file produce the error:
new-route.ts
import { PrismaClient } from '@prisma/client';
const prisma = new PrismaClient();
my docker file:
FROM node:alpine
WORKDIR /app
COPY package.json .
RUN npm install --only=prod
COPY . .
CMD ["npm", "start"]
所有评论(0)