feat: 增加 YAML 配置与一键启动脚本

This commit is contained in:
caoxiaozhu
2026-07-21 16:15:01 +08:00
parent a5fbe5130a
commit 7c38e37b23
15 changed files with 954 additions and 71 deletions

View File

@@ -78,7 +78,10 @@ def verify_password(password: str, stored: str) -> tuple[bool, bool]:
def _psycopg_url(database_url: str) -> str:
return database_url.replace("postgresql+psycopg://", "postgresql://")
sqlalchemy_prefix = "postgresql+psycopg://"
if database_url.startswith(sqlalchemy_prefix):
return f"postgresql://{database_url[len(sqlalchemy_prefix):]}"
return database_url
def _pg_sql(sql: str) -> str:
@@ -1147,4 +1150,3 @@ def get_platform_store() -> PlatformStore:
if _store is None:
_store = PlatformStore()
return _store