Files
Checkmate/docker/dev/docker-compose.yaml
T

30 lines
806 B
YAML
Raw Normal View History

2025-04-20 11:29:53 -07:00
services:
redis:
2025-07-27 03:47:30 +05:30
image: redis:latest
2025-04-20 11:29:53 -07:00
restart: always
2025-07-27 03:47:30 +05:30
ports:
- "6379:6379" # ✅ Expose Redis to host
2025-04-20 11:29:53 -07:00
volumes:
- ./redis/data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 30s
timeout: 10s
retries: 5
start_period: 5s
2025-07-27 03:47:30 +05:30
2025-04-20 11:29:53 -07:00
mongodb:
2025-07-27 03:47:30 +05:30
image: mongo:latest
2025-04-20 11:29:53 -07:00
restart: always
2025-07-27 03:47:30 +05:30
ports:
- "27017:27017" # ✅ Expose MongoDB to host
command: ["mongod", "--quiet", "--replSet", "rs0", "--bind_ip_all"]
2025-04-20 11:29:53 -07:00
volumes:
- ./mongo/data:/data/db
healthcheck:
2025-07-27 03:47:30 +05:30
test: echo "try { rs.status() } catch (err) { rs.initiate({_id:'rs0',members:[{_id:0,host:'localhost:27017'}]}) }" | mongosh --port 27017 --quiet
interval: 5s
timeout: 30s
start_period: 0s
start_interval: 1s
retries: 30