mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-07-07 15:51:28 +08:00
Merge pull request #2668 from InfinityPacer/dev
This commit is contained in:
@@ -1,10 +1,9 @@
|
||||
import secrets
|
||||
from urllib.parse import urlparse
|
||||
|
||||
import sys
|
||||
import threading
|
||||
from pathlib import Path
|
||||
from typing import Optional, List
|
||||
from urllib.parse import urlparse
|
||||
|
||||
from pydantic import BaseSettings, validator
|
||||
|
||||
@@ -41,6 +40,20 @@ class Settings(BaseSettings):
|
||||
DEBUG: bool = False
|
||||
# 是否开发模式
|
||||
DEV: bool = False
|
||||
# 是否在控制台输出 SQL 语句,默认关闭
|
||||
DB_ECHO: bool = False
|
||||
# 是否在获取连接时进行预先 ping 操作,默认开启
|
||||
DB_POOL_PRE_PING: bool = True
|
||||
# 数据库连接池的大小,默认 100
|
||||
DB_POOL_SIZE: int = 100
|
||||
# 数据库连接的回收时间(秒),默认 3600 秒(1 小时)
|
||||
DB_POOL_RECYCLE: int = 3600
|
||||
# 数据库连接池获取连接的超时时间(秒),默认 180 秒
|
||||
DB_POOL_TIMEOUT: int = 180
|
||||
# 数据库连接池最大溢出连接数,默认 5
|
||||
DB_MAX_OVERFLOW: int = 5
|
||||
# SQLite 的 busy_timeout 参数,默认为 60 秒
|
||||
DB_TIMEOUT: int = 60
|
||||
# 配置文件目录
|
||||
CONFIG_DIR: Optional[str] = None
|
||||
# 超级管理员
|
||||
|
||||
Reference in New Issue
Block a user