Added mongo container

This commit is contained in:
Notoric 2024-08-05 18:32:46 +01:00
parent 3ab0e1fa43
commit b75dce5352
2 changed files with 14 additions and 1 deletions

3
.gitignore vendored
View File

@ -10,3 +10,6 @@ backend/.env
# Frontend-specific
frontend/node_modules/
# Database-specific
database/data/

View File

@ -1,5 +1,6 @@
services:
backend:
container_name: backend
build:
context: ./backend
dockerfile: Dockerfile
@ -10,6 +11,7 @@ services:
- ./backend:/app
frontend:
container_name: frontend
build:
context: ./frontend
dockerfile: Dockerfile
@ -19,3 +21,11 @@ services:
- ./frontend:/app
- ./frontend:/node_modules
db:
container_name: database
image: mongodb/mongodb-community-server
ports:
- "27017:27017"
volumes:
- ./database/data:/data/db