Files
moyi-model-intelligence-hub/infra/otari/docker-compose.yml
T

47 lines
1.4 KiB
YAML

name: moyi-otari
services:
otari:
image: ${OTARI_IMAGE:-mzdotai/otari:v0.4.0}
restart: unless-stopped
ports:
- "${OTARI_PORT:-8000}:8000"
volumes:
- ./config.yml:/app/config.yml:ro
- ./service_account.json:/app/service_account.json:ro
environment:
OTARI_CONFIG_PATH: /app/config.yml
OTARI_SECRET_KEY: ${OTARI_SECRET_KEY:?Set OTARI_SECRET_KEY in infra/otari/.env}
OPENAI_API_KEY: ${OPENAI_API_KEY:-}
ANTHROPIC_API_KEY: ${ANTHROPIC_API_KEY:-}
command: ["otari", "serve", "--config", "/app/config.yml"]
depends_on:
postgres:
condition: service_healthy
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
interval: 10s
timeout: 5s
retries: 12
start_period: 15s
postgres:
image: postgres:16-alpine
restart: unless-stopped
ports:
- "${POSTGRES_PORT:-5433}:5432"
environment:
POSTGRES_USER: ${POSTGRES_USER:-otari}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Set POSTGRES_PASSWORD in infra/otari/.env}
POSTGRES_DB: ${POSTGRES_DB:-otari}
volumes:
- otari_postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
interval: 10s
timeout: 5s
retries: 10
volumes:
otari_postgres_data: