mirror of
http://git.xinwangdao.com/cnnc-embedded-parts-detect/detect-gui.git
synced 2025-06-24 05:04:12 +08:00
17 lines
454 B
Python
17 lines
454 B
Python
import os
|
|
|
|
from dynaconf import Dynaconf
|
|
|
|
current_file_dir = os.path.dirname(os.path.abspath(__file__))
|
|
# 设置环境变量
|
|
os.environ['ENV_FOR_DYNACONF'] = 'dev'
|
|
settings = Dynaconf(
|
|
envvar_prefix="DYNACONF",
|
|
settings_files=[
|
|
os.path.join(current_file_dir, '../config/app.toml'),
|
|
os.path.join(current_file_dir, '../config/dev.toml'),
|
|
os.path.join(current_file_dir, '../config/prod.toml')
|
|
],
|
|
environments=True,
|
|
)
|