Files
ailine/docker/frontend/Dockerfile
root a869d884b7
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Failing after 7m1s
docs: 更新文档路径引用,移除硬编码密钥,修复 Docker 配置
2026-04-22 00:43:06 +08:00

22 lines
504 B
Docker

FROM python:3.11-slim
WORKDIR /app
ENV PYTHONPATH=/app
# 设置 pip 国内镜像源
RUN pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
# 复制前端依赖并安装
COPY frontend/requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# 复制前端代码
COPY frontend/src/ ./src/
# 暴露端口
EXPOSE 8501
# 启动命令
CMD ["streamlit", "run", "src.frontend_main", "--server.port", "8501", "--server.address", "0.0.0.0", "--server.baseUrlPath", "/ai"]