修改依赖相关配置

- pyproject `uvicorn[standard] -> fastapi[standard]`
- requirements.txt 使用 `uv export` 生成
- Dockerfile 换用 `python:3.13`
- README pip 安装增加版本提示
This commit is contained in:
wyf9 2025-08-28 04:54:54 +08:00
parent b08a84c63a
commit 1a98d2f926
No known key found for this signature in database
GPG key ID: B126966081BFDBE4
4 changed files with 6 additions and 5 deletions

View file

@ -1,4 +1,4 @@
FROM python:3.9
FROM python:3.13
WORKDIR /app
@ -6,4 +6,4 @@ COPY . .
RUN pip install gunicorn && pip install -r requirements.txt
EXPOSE 8000
CMD ["gunicorn", "-b", "0.0.0.0:8000", "app:app"]
CMD ["gunicorn", "-b", "0.0.0.0:8000", "app:app"]

View file

@ -35,6 +35,7 @@ pdm run app.py
<summary>pip</summary>
```bash
# 请确保使用 Python >= 3.13!
pip install -r requirements.txt
python app.py
```

View file

@ -1,11 +1,11 @@
[project]
name = "mcstatus-api"
version = "0.1.0"
description = "Add your description here"
description = "A Minecraft Server status API based on FastAPI"
readme = "README.md"
requires-python = ">=3.13"
dependencies = [
"fastapi>=0.115.0",
"uvicorn[standard]>=0.30.0",
"fastapi[standard]>=0.115.0",
"uvicorn>=0.30.0",
"mcstatus>=12.0.5",
]

Binary file not shown.