Files
starRiverProperty/scripts/test-env/docker-compose.infra.yml
T
反编译工作区 65fb32d97f fix: restore ZK, use confluentinc/cp-zookeeper:7.5.0 + cp-kafka:7.5.0 (both locally available)
Former-commit-id: 8fffa72c508a4008e2d7790a307eb1e2e4602cde
2026-05-01 22:51:33 +08:00

63 lines
1.5 KiB
YAML

services:
consul:
image: hashicorp/consul:1.22
container_name: v2test-consul
restart: unless-stopped
ports:
- "8500:8500"
command: >
agent -server -bootstrap-expect=1 -ui
-client=0.0.0.0 -bind=0.0.0.0
-data-dir=/consul/data
volumes:
- consul-data:/consul/data
redis:
image: redis:7-alpine
container_name: v2test-redis
restart: unless-stopped
ports:
- "6379:6379"
command: redis-server --requirepass "1qaz!QAZ"
zookeeper:
image: confluentinc/cp-zookeeper:7.5.0
container_name: v2test-zookeeper
restart: unless-stopped
ports:
- "2181:2181"
environment:
ZOOKEEPER_CLIENT_PORT: 2181
ZOOKEEPER_TICK_TIME: 2000
kafka:
image: confluentinc/cp-kafka:7.5.0
container_name: v2test-kafka
restart: unless-stopped
ports:
- "9092:9092"
environment:
KAFKA_BROKER_ID: 1
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_ADVERTISED_LISTENERS: "PLAINTEXT://localhost:9092"
KAFKA_LISTENERS: "PLAINTEXT://:9092"
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
KAFKA_AUTO_CREATE_TOPICS_ENABLE: "true"
depends_on:
- zookeeper
nginx:
image: nginx:alpine
container_name: v2test-nginx
restart: unless-stopped
ports:
- "8090:80"
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ../../frontend:/data/cwos/frontend:ro
- ../../nginx.frontend-local.conf:/etc/nginx/conf.d/default.conf:ro
volumes:
consul-data: