Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions Docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
version: "3.8"

service:
backend:
build: ./server
container_name: backend_container
ports:
- "8000:8000"

volumes:
- ./server:/app/backend
- /app/backend/node_modules

depends_on:
- mongo

mongo:
image: mongo:6.0
container_name: mongo
restart: unless-stopped
ports:
- "27017:27017"

volumes:
- mongo-data:/data/db


frontend:
build: ./client
container_name: frontend_container
ports:
- "5173:5173"

volumes:
- ./client:/app/frontend
- /app/frontend/node_modules

depends_on:
- backend


volumes:
mongo-data:

13 changes: 13 additions & 0 deletions client/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
From node:24-apline3.21

WORKDIR /app/frontend

COPY package*.json ./

RUN npm install

COPY . .

EXPOSE 5173

CMD [ "npm","run","dev" ]
13 changes: 13 additions & 0 deletions server/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
From node:24-apline3.21

WORKDIR /app/backend

COPY package*.json ./

RUN npm install

COPY . .

EXPOSE 8000

CMD [ "npm","start" ]