Spaces:
Runtime error
Runtime error
File size: 579 Bytes
4f1a9f4 3834ddb 4f1a9f4 0e8f624 4f1a9f4 0e8f624 4f1a9f4 0e8f624 4f1a9f4 0e8f624 3834ddb 0e8f624 3834ddb 4f1a9f4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | # Hugging Face Spaces Dockerfile - 超简版
FROM python:3.11-slim
WORKDIR /app
# 只安装必要的Python依赖
RUN pip install --no-cache-dir \
fastapi==0.111.0 \
uvicorn[standard]==0.30.0 \
pandas>=2.0.0 \
pydantic==2.7.4
# 复制静态文件
COPY apps/api/static/ ./apps/api/static/
# 复制数据文件
COPY data/standard_trade_records_sample.csv ./data/
# 复制超简版主文件
COPY apps/api/main_hf_simple.py ./apps/api/main.py
# 暴露端口
EXPOSE 7860
# 启动命令
CMD ["uvicorn", "apps.api.main:app", "--host", "0.0.0.0", "--port", "7860"]
|