Files
aimaq-call-center/docker-compose.aimaq.override.yml
T

138 lines
4.8 KiB
YAML

services:
asterisk-bridge-service:
environment:
AI_VOICE_ENABLED: "1"
AI_VOICE_RUNTIME_SERVICE_URL: "http://ai-voice-runtime-service:8000"
SALES_VOICE_RUNTIME_ENABLED: "1"
ASTERISK_CALLCONTROL_ENABLED: "1"
ASTERISK_WEBRTC_ENABLED: "1"
ai-voice-runtime-service:
environment:
ERROR_TELEGRAM_ALERTS: "1"
ai-orchestrator-service:
environment:
ERROR_TELEGRAM_ALERTS: "1"
api-gateway:
environment:
PLATFORM_SERVICE_URL: "http://platform-service:8000"
QC_SERVICE_URL: "http://call-center-platform:8090"
WFM_SERVICE_URL: "http://call-center-platform:8090"
depends_on: !override
call-center-platform: {condition: service_healthy}
ai-orchestrator-service: {condition: service_healthy}
ai-voice-runtime-service: {condition: service_healthy}
asterisk-bridge-service: {condition: service_started}
auth-service: {condition: service_started}
interaction-service: {condition: service_started}
kb-service: {condition: service_healthy}
recording-service: {condition: service_started}
reporting-service: {condition: service_started}
routing-service: {condition: service_healthy}
sales-service: {condition: service_started}
supervisor-service: {condition: service_healthy}
telegram-adapter-service: {condition: service_healthy}
voice-adapter-service: {condition: service_started}
whatsapp-adapter-service: {condition: service_healthy}
platform-service:
image: ${CALL_CENTER_IMAGE:-call-center-app:active-aimaq}
restart: unless-stopped
env_file:
- ./.env.production
environment:
APP_MODULE: services.platform_service.app:app
CC_DATA_DIR: /app/.data_local
DATABASE_URL: postgresql+psycopg://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB}
SCHEMA_MANAGEMENT_MODE: migrations
CASE_PLATFORM_ENABLED: "1"
volumes:
- ./.data_local:/app/.data_local
extra_hosts:
- host.docker.internal:host-gateway
depends_on:
- postgres
audit-service:
profiles: ["archived"]
customer-service:
profiles: ["archived"]
email-adapter-service:
profiles: ["archived"]
event-bus-service:
profiles: ["archived"]
ivr-service:
profiles: ["archived"]
webchat-adapter-service:
profiles: ["archived"]
qc-service:
profiles: ["archived"]
wfm-service:
profiles: ["archived"]
call-center-platform:
image: ${CALL_CENTER_PLATFORM_IMAGE:-call-center-platform:latest}
restart: unless-stopped
env_file:
- ./.env.production
environment:
DATABASE_URL: jdbc:postgresql://postgres:5432/${POSTGRES_DB}
DATABASE_USER: ${POSTGRES_USER}
DATABASE_PASSWORD: ${POSTGRES_PASSWORD}
DATABASE_POOL_SIZE: "8"
KEYCLOAK_ISSUER_URI: https://aimaq.konturai.kz/auth/realms/callcenter
JAVA_TOOL_OPTIONS: "-XX:MaxRAMPercentage=70 -XX:+ExitOnOutOfMemoryError -XX:+UseSerialGC -Xss512k"
mem_limit: 512m
healthcheck:
test: ["CMD-SHELL", "bash -c 'exec 3<>/dev/tcp/127.0.0.1/8090' || exit 1"]
interval: 15s
timeout: 5s
retries: 10
start_period: 40s
depends_on:
postgres:
condition: service_healthy
keycloak:
image: quay.io/keycloak/keycloak:26.8.0
restart: unless-stopped
command: ["start", "--import-realm"]
env_file:
- ./keycloak/.env
environment:
KC_DB: postgres
KC_DB_URL: jdbc:postgresql://postgres:5432/keycloak
KC_DB_USERNAME: keycloak
KC_DB_POOL_MAX_SIZE: "10"
KC_HOSTNAME: https://aimaq.konturai.kz/auth
KC_HTTP_ENABLED: "true"
KC_HTTP_RELATIVE_PATH: /auth
KC_PROXY_HEADERS: xforwarded
KC_HEALTH_ENABLED: "true"
KC_CACHE: local
KC_LOG_LEVEL: INFO
JAVA_OPTS_KC_HEAP: "-XX:MaxRAMPercentage=65 -XX:InitialRAMPercentage=30"
volumes:
- ./keycloak/callcenter-realm.json:/opt/keycloak/data/import/callcenter-realm.json:ro
mem_limit: 900m
healthcheck:
test: ["CMD-SHELL", "exec 3<>/dev/tcp/127.0.0.1/9000 && printf 'GET /auth/health/ready HTTP/1.1\\r\\nHost: localhost\\r\\nConnection: close\\r\\n\\r\\n' >&3 && grep -q UP <&3"]
interval: 15s
timeout: 5s
retries: 20
start_period: 90s
depends_on:
postgres:
condition: service_healthy
networks:
- default
- common_network
auth-service:
env_file:
- ./.env.production
- ./keycloak/auth-client.env
environment:
OIDC_ENABLED: "1"
OIDC_PROVIDER: keycloak
OIDC_ISSUER_URL: https://aimaq.konturai.kz/auth/realms/callcenter
OIDC_CLIENT_ID: callcenter-auth
OIDC_REDIRECT_URI: https://aimaq.konturai.kz/proxy/auth/auth/oidc/callback
OIDC_SCOPES: openid profile email
OIDC_ROLE_CLAIM: roles
OIDC_ROLE_MAP_JSON: '{"admin":"admin","supervisor":"supervisor","operator":"operator","analyst":"analyst"}'