part 12 done

This commit is contained in:
QkoSad
2024-09-30 15:32:50 +03:00
parent 0a7a469d56
commit 33a5afd017
426 changed files with 46304 additions and 5 deletions
@@ -0,0 +1,38 @@
services:
server:
image: todo-backend-dev
build:
context: .
dockerfile: dev.Dockerfile
volumes:
- ./:/usr/src/app
ports:
- 3000:3000
environment:
REDIS_URL: "redis://redis:6379"
MONGO_URL: "mongodb://the_username:the_password@mongo:27017/the_database"
mongo:
image: mongo
ports:
- 3456:27017
environment:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: example
MONGO_INITDB_DATABASE: the_database
volumes:
- ./mongo/mongo-init.js:/docker-entrypoint-initdb.d/mongo-init.js
- mongo_data:/data/db
redis:
image: redis
ports:
- 3457:6379
# Everything else
command: ['redis-server', '--appendonly', 'yes'] # Overwrite the CMD
volumes: # Declare the volume
- ./redis_data:/data
volumes:
mongo_data: