Added dockerfile and docker-compose
This commit is contained in:
parent
9b5c0b8f06
commit
c0c8046031
|
@ -0,0 +1,16 @@
|
|||
# Typescript Build
|
||||
FROM registry.odit.services/mirror/node:14.15.1-alpine3.12
|
||||
WORKDIR /app
|
||||
COPY package.json ./
|
||||
RUN npm i -g pnpm
|
||||
RUN pnpm i
|
||||
COPY tsconfig.json ./
|
||||
COPY src ./src
|
||||
RUN pnpm run build
|
||||
# final image
|
||||
FROM registry.odit.services/mirror/node:14.15.1-alpine3.12
|
||||
COPY package.json ./
|
||||
RUN npm i -g pnpm
|
||||
RUN pnpm i --prod
|
||||
COPY --from=0 /app/dist dist
|
||||
ENTRYPOINT ["node", "dist/app.js"]
|
|
@ -0,0 +1,9 @@
|
|||
version: "3"
|
||||
services:
|
||||
mailer:
|
||||
build: .
|
||||
ports:
|
||||
- 4010:4010
|
||||
environment:
|
||||
APP_PORT: 4010
|
||||
NODE_ENV: production
|
Loading…
Reference in New Issue