feat: scaffold modular monolith backend architecture

This commit is contained in:
Bot
2026-08-30 23:51:12 +08:00
parent 8b086a8a47
commit 9f6ecf33f9
21 changed files with 273 additions and 0 deletions
+42
View File
@@ -0,0 +1,42 @@
version: '3.8'
services:
backend:
build: .
container_name: wtfx-backend
restart: unless-stopped
ports:
- "8080:8080"
environment:
- ENVIRONMENT=production
- DATABASE_URL=postgresql+asyncpg://wtfx_user:wtfx_pass@postgres:5432/wtfx_db
- REDIS_URL=redis://redis:6379/0
depends_on:
- postgres
- redis
postgres:
image: postgres:16-alpine
container_name: wtfx-postgres
restart: unless-stopped
environment:
POSTGRES_USER: wtfx_user
POSTGRES_PASSWORD: wtfx_pass
POSTGRES_DB: wtfx_db
volumes:
- pgdata:/var/lib/postgresql/data
ports:
- "5432:5432"
redis:
image: redis:7-alpine
container_name: wtfx-redis
restart: unless-stopped
volumes:
- redisdata:/data
ports:
- "6379:6379"
volumes:
pgdata:
redisdata: