| FROM pytorch/pytorch:2.7.0-cuda12.8-cudnn9-devel | |
| # 设置时区 | |
| RUN ln -sf /share/zoneinfo/Asia/Shanghai /etc/localtime && \ | |
| echo "Asia/Shanghai" > /etc/timezone | |
| RUN apt-get update && apt-get install -y \ | |
| curl wget unzip git git-lfs ffmpeg && \ | |
| apt-get clean && rm -rf /var/lib/apt/lists/* | |
| RUN pip install voxcpm && pip cache purge | |
| WORKDIR /workspace | |
| COPY . . | |
| ENV API_TOKEN my_secret_token | |
| ENV VOICE_DOWNLOAD_URL http://localhost/voices.zip | |
| VOLUME /workspace/voices | |
| EXPOSE 7860 | |
| CMD ["python", "api.py"] |