chore(config): 添加环境变量示例及.gitignore更新
- 新增 .env.example,包含 Tushare API、钉钉机器人和PostgreSQL数据库配置模板 - 更新.gitignore,忽略本地配置文件如 .env.local 和 config_local.py - 添加对报表文件命名规则的支持,保留示例文件不忽略 - 删除废弃的 chart.py 及相关图表模块代码 - 新增 config/settings.py,实现从环境变量读取配置的统一接口 - 设置数据目录及缓存目录,确保目录存在,提高配置管理规范性
This commit is contained in:
16
.env.example
Normal file
16
.env.example
Normal file
@@ -0,0 +1,16 @@
|
||||
# ETF策略项目 - 环境变量配置模板
|
||||
# 复制此文件为 .env 并填入真实值
|
||||
|
||||
# ==================== Tushare API ====================
|
||||
TUSHARE_TOKEN=your_tushare_token_here
|
||||
|
||||
# ==================== 钉钉机器人 ====================
|
||||
DINGTALK_WEBHOOK=https://oapi.dingtalk.com/robot/send?access_token=xxx
|
||||
DINGTALK_SECRET=SECxxx
|
||||
|
||||
# ==================== PostgreSQL数据库 ====================
|
||||
DB_HOST=192.168.0.115
|
||||
DB_PORT=5432
|
||||
DB_NAME=etf_db
|
||||
DB_USER=admin
|
||||
DB_PASS=admin
|
||||
Reference in New Issue
Block a user