FROM python:3.10-slim

WORKDIR /app

# 从 PyPI 安装 hikarugo-backend (若发布至 PyPI)
# 注：在未推送到 PyPI 之前本地可以 COPY 并 pip install .
RUN pip install --no-cache-dir hikarugo-backend || pip install --no-cache-dir .

EXPOSE 8000

# 使用注册在 pyproject.toml 中的 hikarugo 命令行工具启动服务
CMD ["hikarugo", "--host", "0.0.0.0", "--port", "8000"]
