services: adc-init: image: alpine:3.24@sha256:294b683cb724975bec92580e1e685676bd4b50bda910ddb8c51d4cabeaec77e6 restart: "no" environment: GOOGLE_ADC_B64: ${GOOGLE_ADC_B64} PERSONAL_VOCABULARY_B64: ${PERSONAL_VOCABULARY_B64:?Personal vocabulary is required} volumes: - google-adc:/credentials command: - /bin/sh - -c - | set -eu umask 077 printf '%s' "$${GOOGLE_ADC_B64}" | base64 -d > /credentials/application_default_credentials.json printf '%s' "$${PERSONAL_VOCABULARY_B64}" | base64 -d > /credentials/personal-vocabulary.json litellm: image: ghcr.io/berriai/litellm:main-stable@sha256:3d88bd757134a00e8c00237b85a021ab1f6d54abb9c1df750f411dbe7256a500 restart: unless-stopped cpus: "1.0" mem_limit: 896m depends_on: adc-init: condition: service_completed_successfully networks: edge-api: aliases: - litellm-api environment: GOOGLE_APPLICATION_CREDENTIALS: /credentials/application_default_credentials.json VERTEXAI_PROJECT: ${VERTEXAI_PROJECT} VERTEXAI_LOCATION: ${VERTEXAI_LOCATION:-global} LITELLM_MASTER_KEY: ${LITELLM_MASTER_KEY} VERTEXAI_ENABLED: "true" ZENMUX_PAYG_API_KEY: ${ZENMUX_PAYG_API_KEY:-} OPENROUTER_API_KEY: ${OPENROUTER_API_KEY:-} OPENAI_API_KEY: ${OPENAI_API_KEY:-} BAILIAN_CN_API_KEY: ${BAILIAN_CN_API_KEY:-} BAILIAN_CN_API_BASE: ${BAILIAN_CN_API_BASE:-https://ws-v68kvjnmhkiejaxo.cn-beijing.maas.aliyuncs.com/api/v1} volumes: - ./models.yaml:/etc/litellm/models.yaml:ro - ./provider_routes.py:/etc/litellm/provider_routes.py:ro - ./provider_policy.py:/etc/litellm/provider_policy.py:ro - ./render_config.py:/etc/litellm/render_config.py:ro - ./vertex_dictation.py:/etc/litellm/vertex_dictation.py:ro - ./zenmux_transcription.py:/etc/litellm/zenmux_transcription.py:ro - ./bailian_transcription.py:/etc/litellm/bailian_transcription.py:ro - google-adc:/credentials:ro entrypoint: ["/bin/sh", "-c"] command: - python /etc/litellm/render_config.py && exec python /etc/litellm/vertex_dictation.py --config /tmp/litellm.yaml --host 0.0.0.0 --port ${LITELLM_PORT:-1049} --num_workers 1 logging: driver: json-file options: max-size: 1m max-file: "2" healthcheck: test: [CMD, python, -c, 'import urllib.request; urllib.request.urlopen("http://127.0.0.1:1049/health/liveliness", timeout=5)'] interval: 30s timeout: 10s retries: 5 start_period: 120s volumes: google-adc: networks: edge-api: name: dc1-api