mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-27 04:49:47 +01:00
- Defaults and config aligned with English-first product surface - Adds/removes ASR/TTS paths; drops China-only provider implementations and bundled SenseVoice assets - Westernizes prompts, plugin/tool copy, connection and handler behavior on upstream fixes - Powermem max_tokens and OpenAI no-thinking guard preserved on downstream path
91 lines
2.6 KiB
YAML
91 lines
2.6 KiB
YAML
# Docker Installation All Modules
|
|
|
|
version: '3'
|
|
services:
|
|
# Server module
|
|
xiaozhi-esp32-server:
|
|
image: ghcr.io/lapy/xiaozhi-esp32-server:server_latest
|
|
container_name: xiaozhi-esp32-server
|
|
depends_on:
|
|
- xiaozhi-esp32-server-db
|
|
- xiaozhi-esp32-server-redis
|
|
restart: always
|
|
networks:
|
|
- default
|
|
ports:
|
|
# WebSocket server
|
|
- "8000:8000"
|
|
# HTTP service port for visual analysis interface
|
|
- "8003:8003"
|
|
security_opt:
|
|
- seccomp:unconfined
|
|
environment:
|
|
- TZ=UTC
|
|
volumes:
|
|
# Configuration file directory
|
|
- ./data:/opt/xiaozhi-esp32-server/data
|
|
# Model file mount, very important
|
|
- ./models/vosk:/opt/xiaozhi-esp32-server/models/vosk
|
|
# manager-api and manager-web modules
|
|
xiaozhi-esp32-server-web:
|
|
image: ghcr.io/lapy/xiaozhi-esp32-server:web_latest
|
|
container_name: xiaozhi-esp32-server-web
|
|
restart: always
|
|
networks:
|
|
- default
|
|
depends_on:
|
|
xiaozhi-esp32-server-db:
|
|
condition: service_healthy
|
|
xiaozhi-esp32-server-redis:
|
|
condition: service_healthy
|
|
ports:
|
|
# Smart control panel
|
|
- "8002:8002"
|
|
environment:
|
|
- TZ=UTC
|
|
- SPRING_DATASOURCE_DRUID_URL=jdbc:mysql://xiaozhi-esp32-server-db:3306/xiaozhi_esp32_server?useUnicode=true&characterEncoding=UTF-8&serverTimezone=UTC&nullCatalogMeansCurrent=true&connectTimeout=30000&socketTimeout=30000&autoReconnect=true&failOverReadOnly=false&maxReconnects=10
|
|
- SPRING_DATASOURCE_DRUID_USERNAME=root
|
|
- SPRING_DATASOURCE_DRUID_PASSWORD=123456
|
|
- SPRING_DATA_REDIS_HOST=xiaozhi-esp32-server-redis
|
|
- SPRING_DATA_REDIS_PASSWORD=
|
|
- SPRING_DATA_REDIS_PORT=6379
|
|
volumes:
|
|
# Configuration file directory
|
|
- ./uploadfile:/uploadfile
|
|
# Database module
|
|
xiaozhi-esp32-server-db:
|
|
image: mysql:latest
|
|
container_name: xiaozhi-esp32-server-db
|
|
healthcheck:
|
|
test: [ "CMD", "mysqladmin" ,"ping", "-h", "localhost" ]
|
|
timeout: 45s
|
|
interval: 10s
|
|
retries: 10
|
|
restart: always
|
|
networks:
|
|
- default
|
|
expose:
|
|
- 3306
|
|
volumes:
|
|
- ./mysql/data:/var/lib/mysql
|
|
environment:
|
|
- TZ=UTC
|
|
- MYSQL_ROOT_PASSWORD=123456
|
|
- MYSQL_DATABASE=xiaozhi_esp32_server
|
|
- MYSQL_INITDB_ARGS="--character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci"
|
|
# Redis module
|
|
xiaozhi-esp32-server-redis:
|
|
image: redis:8.0
|
|
expose:
|
|
- 6379
|
|
container_name: xiaozhi-esp32-server-redis
|
|
restart: always
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 3
|
|
networks:
|
|
- default
|
|
networks:
|
|
default:
|