ai generated solutions to our ai generated problems

This commit is contained in:
2026-06-20 00:50:28 +01:00
parent 22bff51147
commit 50439720dd
4 changed files with 86 additions and 255 deletions
+6
View File
@@ -125,6 +125,12 @@ API_RATE_LIMIT_WINDOW_MS=60000
API_RATE_LIMIT_MAX=120
```
On startup, the web server preloads the critical public snapshots before
signalling PM2 `ready`: team leaderboard, player leaderboard, home teams, and
recent games. `/health` includes a `public_data` block with the latest preload
status. A same-origin `POST /api/cache/prewarm` refreshes those snapshots on
demand.
## Reverse proxy / Cloudflare
The server only honours `CF-Connecting-IP`, `X-Forwarded-For`, `X-Forwarded-Proto`,