feat(trader): live bridge token 改从 config 读取,免容器重建
容器 docker run(非 compose)注入 BRIDGE_TOKEN env 需重建容器,风险大。改为 live_cfg.bridge_token 优先、fallback BRIDGE_TOKEN env。run_live_step 每次 load_config,改 config 免重启即生效。 - _shadow_trades_to_bridge + reconcile_from_bridge 两处 token 读取 - config: live.bridge_token 占位空值(真实值填 NAS gitignored config,不入库) - tests: +6 测试(config优先/env fallback/都无跳过),191 passed
This commit is contained in:
@@ -41,9 +41,11 @@ performance:
|
||||
risk_free_rate: 0.02
|
||||
|
||||
# 实盘集成(D期,spec §5)— 默认关闭,D-4a 联调再开
|
||||
# bridge_token 走环境变量 BRIDGE_TOKEN,不写入 yaml(不进 git)
|
||||
# bridge_token 优先从 config 读,fallback 环境变量 BRIDGE_TOKEN
|
||||
live:
|
||||
enabled: false # 总开关(false=影子分支整个跳过,live_step 行为不变)
|
||||
bridge_url: https://bridge.mysanguo.top
|
||||
shadow: true # 模式A影子下单(模拟撮合为准,信号同步POST bridge影子)
|
||||
mode_b: false # D-4c 模式B: bridge回报校正账本(默认关,切实盘再开)
|
||||
# 和 Windows bridge 同值;不进 git。占位空值,真实值部署时填实际 config
|
||||
bridge_token:
|
||||
|
||||
Reference in New Issue
Block a user