Skip to content

Commit

Permalink
👷 feat: Dockerize
Browse files Browse the repository at this point in the history
  • Loading branch information
mtsammy40 committed Jun 12, 2024
1 parent d6f44a3 commit beddd2a
Show file tree
Hide file tree
Showing 6 changed files with 1,053 additions and 47 deletions.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.git
.gitignore
src/node_modules/
10 changes: 10 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Dockerfile

FROM node:20-alpine3.20
RUN mkdir -p /opt/app
WORKDIR /opt/app
COPY package.json package-lock.json processes.json ./
COPY dist/ .
RUN npm install --omit=dev
EXPOSE 5001
CMD [ "npm", "run", "pm2:prod"]
13 changes: 13 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: "3.9"
services:
crypto-alerts-api:
image: mtsammy40/crypto_alerts_api:latest
environment:
NODE_ENV: ${NODE_ENV}
MONGO_URI: ${MONGO_URI}
REDIS_URI: ${REDIS_URI}
NOVU_API_KEY: ${NOVU_API_KEY}
NOVU_APP_ID: ${NOVU_APP_ID}
NOVU_ENVIRONMENT_ID: ${NOVU_ENVIRONMENT_ID}
ports:
- '5001:5001'
Loading

0 comments on commit beddd2a

Please sign in to comment.