Free, open-source screen sharing for private live streams with friends. Watch together in a browser or self-host Piik. 免费开源的私密屏幕共享,支持游戏直播、一起看电影与自部署。
docs(media): finalize UDP migration constraints
AAA25a988987c51
diff --git a/AGENTS.md b/AGENTS.mdindex 2805ec02..3c5c0a26 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -4,9 +4,9 @@- Build private, low-latency game screen sharing for one broadcaster and a small group of trusted friends.- This is not a public or large-scale streaming product; users can use OBS/Twitch-class services for that workload.-- Keep the media path P2P-first. Use centralized services for rooms, authentication, signaling, STUN, observability, and bounded SFU-root capacity; TURN is an optional transport compatibility fallback.+- Keep media distributed and automatic. Use centralized services for rooms, authentication, signaling, STUN, observability, and bounded SFU-root capacity. TURN is an optional authenticated selected-edge compatibility transport, disabled unless explicitly configured; it is not a media topology.- Let viewers join from a normal desktop or mobile browser without installing the sender application.-- STUN is required. The target automatic ladder is direct/peer ICE over UDP, then an SFU virtual parent feeding at most two roots, then optional authenticated TURN for deployments that explicitly cover restrictive networks, followed by a clear bounded failure. Ordinary peer edges must not receive TURN candidates by default merely to maximize rare-network coverage. HTTPS/WSS remains TLS/TCP and is independent of this media-transport policy.+- STUN is required. The target ladder is direct/peer UDP, then an SFU/UDP virtual parent feeding at most two roots, then optional authenticated selected-edge TURN, followed by a clear bounded failure. Ordinary peer edges must not receive TURN candidates by default. HTTPS/WSS remains TLS/TCP and is independent of this media-transport policy.- Every non-server endpoint has at most two active downstream media edges; an upstream receive edge does not consume this upload budget. Browser relays remain stricter at one downstream edge until their re-encode/resource gates pass. Central media normally serves at most two roots; extra server-fed exceptional viewers require an explicit deployment egress/admission cap and must never create unbounded fanout.- Treat a web client as the initial delivery target. A packaged desktop sender or native capture helper is a later optimization, not an assumed requirement.- Do not silently change the product into an always-SFU conferencing system. An SFU is a virtual parent for one or two necessary roots whose peer descendants remain distributed; record any broader topology change as an ADR with measured justification.diff --git a/deploy/nginx/share.bonfire.icu.conf.example b/deploy/nginx/share.bonfire.icu.conf.exampleindex 2f1c8786..b14407ef 100644--- a/deploy/nginx/share.bonfire.icu.conf.example+++ b/deploy/nginx/share.bonfire.icu.conf.example@@ -45,8 +45,9 @@ server {return 404;}- # LiveKit client v0 validates this retired path before joining. Reject it- # explicitly so the broader current-v1 proxy cannot accept an old SDK.+ # Pinned [email protected] still tries this v0 endpoint after a+ # ServiceNotFound response. Reject that fallback with a no-log 404;+ # /rtc/v1* below is the accepted SDK path.location = /rtc/validate {access_log off;error_log /dev/null crit;diff --git "a/docs/\346\226\271\346\241\210\350\256\276\350\256\241.md" "b/docs/\346\226\271\346\241\210\350\256\276\350\256\241.md"index 23947d4f..b0a9489f 100644--- "a/docs/\346\226\271\346\241\210\350\256\276\350\256\241.md"+++ "b/docs/\346\226\271\346\241\210\350\256\276\350\256\241.md"@@ -312,10 +312,10 @@ hop 按[低服务器成本媒体路由](./research/low-server-media-routes.md)状态:Proposed / Experiment Only。该扩展不改变上面的已部署 PoC,也不表示正式采用。-部署可在 `PEER_ASSISTED_MEDIA=true` 时用可选的-`PEER_ASSISTED_ROOM_IDS` 精确限制实验房间。非空值只接受逗号分隔、符合现有-room code 规则且不重复的 ID;非法配置启动即失败。未配置或空值为兼容旧行为而-表示全部房间,因此隔离灰度必须填写至少一个精确 ID。未命中房间不得进入+部署设置 `PEER_ASSISTED_MEDIA=true` 时必须同时提供非空的+`PEER_ASSISTED_ROOM_IDS` 精确限制实验房间。该值只接受逗号分隔、符合现有+room code 规则且不重复的 ID;缺失、空值或非法配置都启动失败,不存在全房间+fail-open。未命中房间不得进入`HybridMediaRouter`、房间质量同步或 LiveKit 兜底,route 字段、定向信令、停止、重连和删除保持普通 P2P 行为;ordinary STUN-only ICE snapshot 是进程级契约,不为未命中房间保留旧 TURN wire。该边界不增加 UI、用户选择或百分比框架。