name: teaching-feedback x-api-base: &api-base image: teaching-feedback-api:${APP_VERSION:-0.2.0} x-default-logging: &default-logging driver: local options: max-size: "20m" max-file: "5" x-observability-labels: &observability-labels observability.logs: "true" observability.application: "teaching-feedback" observability.environment: "lan" observability.app_version: "${APP_VERSION:-0.2.0}" services: funasr: image: teaching-feedback-funasr:1.0.0 build: context: ./asr-service dockerfile: Dockerfile args: DEBIAN_MIRROR: http://mirrors.ustc.edu.cn PYPI_INDEX_URL: https://mirrors.ustc.edu.cn/pypi/simple APP_VERSION: ${APP_VERSION:-0.2.0} GIT_SHA: ${GIT_SHA:-unknown} environment: APP_ENV: lan APP_VERSION: ${APP_VERSION:-0.2.0} GIT_SHA: ${GIT_SHA:-unknown} LOG_FORMAT: json ASR_MODEL: paraformer-zh ASR_VAD_MODEL: fsmn-vad ASR_PUNC_MODEL: ct-punc ASR_DEVICE: cpu ASR_MAX_CONCURRENCY: "1" ASR_BATCH_SIZE_SECONDS: "300" MODELSCOPE_CACHE: /models labels: *observability-labels logging: *default-logging volumes: - funasr-model-cache:/models restart: unless-stopped init: true healthcheck: test: - CMD - python - -c - "import urllib.request; urllib.request.urlopen('http://127.0.0.1:10095/health', timeout=3)" interval: 15s timeout: 5s retries: 80 start_period: 10m shm_size: 1gb migrate: <<: *api-base env_file: - ./server/.env environment: APP_ENV: lan APP_VERSION: ${APP_VERSION:-0.2.0} GIT_SHA: ${GIT_SHA:-unknown} LOG_FORMAT: json labels: *observability-labels logging: *default-logging command: - migrate restart: "no" healthcheck: disable: true api: <<: *api-base build: context: ./server dockerfile: Dockerfile args: DEBIAN_MIRROR: http://mirrors.ustc.edu.cn APP_VERSION: ${APP_VERSION:-0.2.0} GIT_SHA: ${GIT_SHA:-unknown} env_file: - ./server/.env environment: APP_ENV: lan APP_VERSION: ${APP_VERSION:-0.2.0} GIT_SHA: ${GIT_SHA:-unknown} LOG_FORMAT: json HOST: 0.0.0.0 PORT: "8080" AUDIO_STORAGE_DIR: /data/audio ASR_PROVIDER: local LOCAL_ASR_URL: http://funasr:10095 ASR_REQUEST_TIMEOUT_SECONDS: "1800" ASR_WORKER_CONCURRENCY: "1" ASR_JOB_LEASE_SECONDS: "3600" DATABASE_MAX_CONNECTIONS: "5" ALLOW_DEVELOPMENT_USER_HEADER: "false" labels: *observability-labels logging: *default-logging ports: - "39180:8080" volumes: - audio-data:/data/audio restart: unless-stopped init: true depends_on: migrate: condition: service_completed_successfully funasr: condition: service_healthy volumes: funasr-model-cache: name: teaching-feedback-funasr-model-cache audio-data: name: teaching-feedback-audio