iop/docker-compose.yml
toki e7e158b113 정리: 프로젝트 이름 참조를 iop로 맞춘다
저장소 디렉터리명이 iop로 정리된 상태와 문서, Docker 빌드 경로, 테스트 fixture의 워크스페이스 표기가 어긋나지 않도록 맞춘다.
2026-05-20 07:27:46 +09:00

75 lines
2.3 KiB
YAML

name: ${COMPOSE_PROJECT_NAME:-iop-dev}
services:
postgres:
image: postgres:17-alpine
restart: unless-stopped
environment:
POSTGRES_USER: ${IOP_POSTGRES_USER:-iop}
POSTGRES_PASSWORD: ${IOP_POSTGRES_PASSWORD:-iop_dev_password}
POSTGRES_DB: ${IOP_POSTGRES_DB:-iop-control-plane-dev}
ports:
- "${IOP_POSTGRES_PORT:-5432}:5432"
volumes:
- control-plane-postgres:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U \"$${POSTGRES_USER}\" -d \"$${POSTGRES_DB}\""]
interval: 10s
timeout: 3s
retries: 5
redis:
image: redis:7-alpine
restart: unless-stopped
command: ["redis-server", "--appendonly", "yes"]
ports:
- "${IOP_REDIS_PORT:-6379}:6379"
volumes:
- control-plane-redis:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 3s
retries: 5
control-plane:
build:
context: ..
dockerfile: iop/apps/control-plane/Dockerfile
restart: unless-stopped
environment:
IOP_DATABASE_URL: "postgres://${IOP_POSTGRES_USER:-iop}:${IOP_POSTGRES_PASSWORD:-iop_dev_password}@postgres:5432/${IOP_POSTGRES_DB:-iop-control-plane-dev}?sslmode=disable"
IOP_REDIS_URL: "redis://redis:6379/${IOP_REDIS_DB:-2}"
IOP_REDIS_KEY_PREFIX: "${IOP_REDIS_KEY_PREFIX:-iop:control-plane:dev:}"
ports:
- "${IOP_CONTROL_PLANE_HTTP_PORT:-9080}:9080"
- "${IOP_CONTROL_PLANE_WIRE_PORT:-19080}:19080"
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "-qO-", "http://127.0.0.1:9080/healthz"]
interval: 10s
timeout: 3s
retries: 5
web:
build:
context: ./apps/web
dockerfile: Dockerfile
environment:
CONTROL_PLANE_INTERNAL_HTTP_URL: "http://control-plane:9080"
NEXT_PUBLIC_CONTROL_PLANE_HTTP_URL: "http://localhost:${IOP_CONTROL_PLANE_HTTP_PORT:-9080}"
NEXT_PUBLIC_CONTROL_PLANE_WIRE_URL: "tcp://localhost:${IOP_CONTROL_PLANE_WIRE_PORT:-19080}"
restart: unless-stopped
ports:
- "${IOP_WEB_PORT:-3000}:3000"
depends_on:
control-plane:
condition: service_healthy
volumes:
control-plane-postgres:
control-plane-redis: