docs: 移动蓝绿部署指南到 troubleshooting 目录

This commit is contained in:
Simon
2026-07-05 17:03:36 +08:00
parent ab90db3d3d
commit ca7c6d937a
91 changed files with 4841 additions and 406 deletions
+28
View File
@@ -0,0 +1,28 @@
#!/usr/bin/env python3
"""检查 alembic 迁移版本"""
import asyncio
import asyncpg
import os
async def check_heads():
conn = await asyncpg.connect(
host='postgres',
user='wecom',
password='wecom_secret_2026',
database='wecom_it_desk'
)
# 检查 alembic_version 表
rows = await conn.fetch('SELECT version_num, branch_from, depends_on FROM alembic_version ORDER BY rank')
if not rows:
print("No migration versions found!")
else:
print(f"Found {len(rows)} migration version(s):")
for r in rows:
print(f" - {r['version_num']} (branch_from: {r['branch_from']}, depends_on: {r['depends_on']})")
await conn.close()
asyncio.run(check_heads())