feat(platform): 增加履约分类映射管理并锁定迁移
This commit is contained in:
@@ -196,6 +196,11 @@ def run_migrations():
|
||||
from alembic import command
|
||||
from alembic.config import Config
|
||||
|
||||
from .migrations.immutability import verify_manifest
|
||||
|
||||
# Alembic 不会检测旧迁移内容被改写。启动前先锁文件哈希,避免已执行迁移
|
||||
# 在全新环境产生另一套结构。
|
||||
verify_manifest()
|
||||
config = Config(str(PROJECT_ROOT / "alembic.ini"))
|
||||
config.set_main_option(
|
||||
"script_location", str(PROJECT_ROOT / "web" / "backend" / "migrations")
|
||||
|
||||
Reference in New Issue
Block a user