Commit 7191c72
committed
feat: Clawdi platform integration patches
Four minimal patches for Clawdi's multi-tenant dashboard integration:
1. web_server.py: HERMES_SESSION_TOKEN env override — reverse-proxied
deployments set a stable token so the SPA can authenticate across
restarts (mirrors upstream PR NousResearch#9800 pattern).
2. web_server.py: load_hermes_dotenv() at module init — uvicorn launches
web_server.py directly, bypassing hermes_cli/main.py where the dotenv
loader normally runs. Without this, the HERMES_SESSION_TOKEN written
to ~/.hermes/.env is never loaded into os.environ.
3. web_server.py: expose plain `value` field for non-password env vars
in GET /api/env — lets the dashboard round-trip comma-separated
allow-lists (TELEGRAM_ALLOWED_USERS, FEISHU_ALLOWED_USERS, etc.)
without forcing users to retype them.
4. config.py: register FEISHU_ALLOWED_USERS in OPTIONAL_ENV_VARS — the
Feishu gateway adapter reads this from os.getenv() but it was missing
from the registration list, so GET /api/env never surfaced it.1 parent 524cbab commit 7191c72
2 files changed
Lines changed: 53 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2349 | 2349 | | |
2350 | 2350 | | |
2351 | 2351 | | |
| 2352 | + | |
| 2353 | + | |
| 2354 | + | |
| 2355 | + | |
| 2356 | + | |
| 2357 | + | |
| 2358 | + | |
| 2359 | + | |
| 2360 | + | |
| 2361 | + | |
| 2362 | + | |
| 2363 | + | |
| 2364 | + | |
| 2365 | + | |
| 2366 | + | |
2352 | 2367 | | |
2353 | 2368 | | |
2354 | 2369 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
50 | 51 | | |
51 | 52 | | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
52 | 67 | | |
53 | 68 | | |
54 | 69 | | |
| |||
67 | 82 | | |
68 | 83 | | |
69 | 84 | | |
70 | | - | |
71 | | - | |
72 | | - | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
73 | 98 | | |
74 | | - | |
| 99 | + | |
75 | 100 | | |
76 | 101 | | |
77 | 102 | | |
| |||
1219 | 1244 | | |
1220 | 1245 | | |
1221 | 1246 | | |
| 1247 | + | |
1222 | 1248 | | |
1223 | 1249 | | |
1224 | 1250 | | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
1225 | 1258 | | |
1226 | 1259 | | |
1227 | 1260 | | |
1228 | | - | |
| 1261 | + | |
1229 | 1262 | | |
1230 | 1263 | | |
1231 | 1264 | | |
| |||
0 commit comments