Files
cjyyzx/docker-compose.gateway.yml
T
xiaohei 428644e286
Revalidate Docs / Revalidate Docs (push) Failing after 2s
E2E CI / Check Duplicate Run (push) Failing after 5s
Test CI / Check Duplicate Run (push) Failing after 6s
E2E CI / Test Web App (push) Has been skipped
Test CI / Test Packages (push) Has been skipped
Test CI / Test App (shard 1/3) (push) Has been skipped
Test CI / Test App (shard 2/3) (push) Has been skipped
Test CI / Test App (shard 3/3) (push) Has been skipped
Test CI / Test Desktop App (push) Has been skipped
🔄 Branch Synchronization / sync-branches (push) Failing after 11s
Test CI / Test Database (push) Has been skipped
Test CI / Merge and Upload App Coverage (push) Has been skipped
Database Schema Visualization CI / build (push) Failing after 4m14s
Enterprise AI Workspace prototype: LobeChat (de-branded) + Enterprise Gateway + Postgres/Redis stack
2026-04-21 12:58:00 +08:00

77 lines
2.3 KiB
YAML

services:
db:
image: postgres:16-alpine
restart: unless-stopped
environment:
POSTGRES_USER: ${POSTGRES_USER:-eg}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-eg_pw}
POSTGRES_DB: ${POSTGRES_DB:-enterprise_gateway}
ports:
- "${POSTGRES_PORT:-5432}:5432"
volumes:
- pgdata:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-eg} -d ${POSTGRES_DB:-enterprise_gateway}"]
interval: 3s
timeout: 3s
retries: 30
api:
build:
context: ./apps/api
dockerfile: Dockerfile
restart: unless-stopped
depends_on:
db:
condition: service_healthy
environment:
DATABASE_URL: postgresql://${POSTGRES_USER:-eg}:${POSTGRES_PASSWORD:-eg_pw}@db:5432/${POSTGRES_DB:-enterprise_gateway}?schema=public
API_PORT: ${API_PORT:-3001}
MOCK_MODE: ${MOCK_MODE:-true}
AUTH_MODE: ${AUTH_MODE:-dev}
NODE_ENV: ${NODE_ENV:-development}
LOG_LEVEL: ${LOG_LEVEL:-info}
GONGDAN_API_URL: ${GONGDAN_API_URL:-}
GONGDAN_API_KEY: ${GONGDAN_API_KEY:-}
SUPER_OPS_API_URL: ${SUPER_OPS_API_URL:-}
SUPER_OPS_API_KEY: ${SUPER_OPS_API_KEY:-}
CLOUDCOST_API_URL: ${CLOUDCOST_API_URL:-}
CLOUDCOST_BEARER: ${CLOUDCOST_BEARER:-}
KB_AGENT_URL: ${KB_AGENT_URL:-}
KB_API_KEY: ${KB_API_KEY:-}
AI_SEARCH_URL: ${AI_SEARCH_URL:-}
AI_SEARCH_KEY: ${AI_SEARCH_KEY:-}
SANDBOX_URL: ${SANDBOX_URL:-}
SANDBOX_KEY: ${SANDBOX_KEY:-}
DOC_AGENT_URL: ${DOC_AGENT_URL:-}
DOC_AGENT_KEY: ${DOC_AGENT_KEY:-}
CASDOOR_URL: ${CASDOOR_URL:-}
CORS_ORIGINS: ${CORS_ORIGINS:-http://localhost:3010}
ALLOW_DATA_LOSS: ${ALLOW_DATA_LOSS:-false}
ports:
- "${API_PORT:-3001}:3001"
healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost:3001/health"]
interval: 5s
timeout: 3s
retries: 30
start_period: 20s
web:
build:
context: ./apps/web
dockerfile: Dockerfile
restart: unless-stopped
depends_on:
api:
condition: service_healthy
environment:
API_INTERNAL_URL: http://api:3001
NEXT_PUBLIC_API_URL: ${NEXT_PUBLIC_API_URL:-http://localhost:3001}
NODE_ENV: production
ports:
- "${WEB_PORT:-3010}:3000"
volumes:
pgdata: