🚧 Dockerfile and script changes

This commit is contained in:
Axel Olausson Holtenäs 2022-10-23 18:11:31 +02:00
parent 1a5190aef8
commit a84222965f
No known key found for this signature in database
GPG key ID: BEDBB4D61E6C8462
2 changed files with 3 additions and 4 deletions

View file

@ -20,8 +20,6 @@ FROM node:19
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package*.json ./
COPY --from=builder /app/dist ./dist
COPY --from=builder /app/prisma ./prisma
RUN npx prisma migrate deploy
EXPOSE 3000
CMD [ "npm", "run", "start" ]
CMD [ "npm", "run", "start:migrate:prod" ]

View file

@ -9,6 +9,7 @@
"prisma:generate": "prisma generate",
"test": "jest",
"start": "node dist",
"start:migrate:prod": "prisma migrate deploy && npm run start",
"prettier-format": "prettier \"src/**/*.ts\" --write",
"lint": "eslint ./src --ext .ts"
},