mirror of
https://github.com/fastapiadmin/FastapiAdmin.git
synced 2026-09-22 13:05:18 +00:00
移除RELOAD配置项,改为根据环境变量动态设置 调整banner显示逻辑,确保在日志初始化后执行 将部分错误日志改为警告级别 更新.gitignore,添加缓存目录 重构测试文件,添加健康检查测试
11 lines
354 B
Python
11 lines
354 B
Python
from app.config.path_conf import BANNER_FILE
|
||
from app.core.logger import log
|
||
|
||
def worship(env: str) -> None:
|
||
"""
|
||
获取项目启动Banner(优先读取 banner.txt)
|
||
"""
|
||
if BANNER_FILE.exists():
|
||
banner = BANNER_FILE.read_text(encoding='utf-8')
|
||
banner = f"🚀 当前运行环境: {env}\n{banner}"
|
||
log.info(banner) |