Proxy btcdata WebSocket through btcprice for remote access

Browser can't reach the LAN-only btcdata WebSocket when accessing
btcprice remotely (Tailscale/Cloudflare Tunnel). Add a /ws/price
proxy route that relays btcdata frames to the browser so only
btcprice needs to be reachable.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-28 13:43:05 +01:00
co-authored by Claude Opus 4.6
parent 6afaa228c3
commit 32a1509482
7 changed files with 112 additions and 21 deletions
+3
View File
@@ -36,5 +36,8 @@
{:base-path "/api"}
:reitit.routes/ui
{:base-path ""}
:reitit.routes/ws-proxy
{:base-path ""
:btcdata-url #or [#env BTCDATA_URL "http://localhost:4100"]}}