Docker 容器化部署
OneTTS 提供了生产级 Docker 镜像与 docker-compose.yml,实现零配置一键部署。
🚀 Docker Compose 一键启动
1. 配置文件 docker-compose.yml
yaml
services:
onetts:
image: codeandxv/onetts:latest
container_name: onetts-server
restart: unless-stopped
ports:
- "8030:8030"
volumes:
- ./config.yaml:/app/config.yaml:ro
- ./data:/app/data:rw
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8030/health"]
interval: 30s
timeout: 5s
retries: 32. 启动容器
bash
docker compose up -d3. 检查服务健康状态
bash
curl http://localhost:8030/health
# {"status":"ok","service":"OneTTS"}