19 lines
260 B
Text
19 lines
260 B
Text
|
FROM node:18
|
||
|
WORKDIR /app
|
||
|
|
||
|
# Packages
|
||
|
COPY package*.json ./
|
||
|
RUN npm install -D
|
||
|
|
||
|
# Database schema
|
||
|
COPY schema.prisma .
|
||
|
RUN npx prisma generate
|
||
|
|
||
|
# Typescript compiling
|
||
|
COPY tsconfig.json .
|
||
|
COPY src ./src
|
||
|
RUN npx tsc
|
||
|
|
||
|
# Run the app
|
||
|
CMD ["node", "dist/index.js"]
|