feat: mysql 单后端精简分支 — SQLAlchemy 2.0 async + aiomysql + alembic

This commit is contained in:
2026-08-21 21:30:45 +08:00
parent 981bee5a46
commit 35bdc60b77
12 changed files with 31 additions and 278 deletions

View File

@@ -1,13 +1,6 @@
# ===== 数据库后端mysql 或 mongodb =====
DB_BACKEND=mongodb
# ===== MySQLDB_BACKEND=mysql 时必填)=====
# ===== MySQL =====
MYSQL_DSN=mysql+aiomysql://root:root@127.0.0.1:3306/app?charset=utf8mb4
# ===== MongoDBDB_BACKEND=mongodb 时必填)=====
MONGO_DSN=mongodb://127.0.0.1:27017
MONGO_DB=app
# ===== 应用 =====
APP_NAME=fastapi-template
APP_ENV=dev