Files
stock/docker-compose.dev.yml
2026-06-11 01:41:47 +08:00

33 lines
696 B
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 本地开发专用只启动基础设施PostgreSQL + Redis
# 前后端在宿主机直接运行,无需 Docker
#
# 使用方式:
# docker-compose -f docker-compose.dev.yml up -d
version: "3.9"
services:
postgres:
image: postgres:16-alpine
container_name: stock_postgres_dev
environment:
POSTGRES_USER: stock
POSTGRES_PASSWORD: stockpass123
POSTGRES_DB: stockdb
ports:
- "5432:5432"
volumes:
- postgres_dev_data:/var/lib/postgresql/data
redis:
image: redis:7-alpine
container_name: stock_redis_dev
ports:
- "6379:6379"
volumes:
- redis_dev_data:/data
volumes:
postgres_dev_data:
redis_dev_data: