Merge pull request #24 from zonghaoyuan/fix/optional-image-proxy
fix(play): make scene-image proxy opt-in (default direct-connect)
This commit is contained in:
+21
-8
@@ -56,15 +56,28 @@ TTS_SPEECH_MODEL=mimo-v2.5-tts
|
||||
# Text/story/voice still run normally. Great for iterating on TTS.
|
||||
MOCK_IMAGE=false
|
||||
|
||||
# ---- 5b. Image proxy (Cloudflare Worker, optional) -----------------
|
||||
# Chrome's direct fetch of im.runware.ai is unreliable on some networks
|
||||
# (ERR_QUIC_PROTOCOL_ERROR mid-stream → partial bytes → <img> renders
|
||||
# progressively from top to bottom). Routing the fetch through a CF Worker
|
||||
# (see worker/) avoids the QUIC fragility and adds edge caching + CORS.
|
||||
# Empty → no proxy → direct fetch (fine when the network behaves).
|
||||
# NEXT_PUBLIC_ vars are inlined at BUILD time — set in Vercel project settings.
|
||||
# Deploy the Worker per worker/wrangler.toml, then paste the workers.dev URL:
|
||||
# ---- 5b. Image proxy (Cloudflare Worker, OPTIONAL) -----------------
|
||||
# Leave NEXT_PUBLIC_IMAGE_PROXY_URL blank (the default) and the browser
|
||||
# fetches images directly from the provider — exactly as the app worked
|
||||
# before this proxy existed. The ALLOWED_HOSTS value below is inert until
|
||||
# a proxy URL is set, so you're completely unaffected; skip this section.
|
||||
#
|
||||
# Why you might want it: Chrome's direct fetch of im.runware.ai is unreliable
|
||||
# on some networks (ERR_QUIC_PROTOCOL_ERROR mid-stream → partial bytes →
|
||||
# <img> paints progressively top-to-bottom). Routing the fetch through a tiny
|
||||
# Cloudflare Worker re-fetches server-to-server (no QUIC fragility) and serves
|
||||
# over HTTP/2 — atomic paint, plus edge caching + CORS.
|
||||
#
|
||||
# Deploy your own in ~1 min (one-click "Deploy to Cloudflare" button):
|
||||
# https://github.com/zonghaoyuan/infiplot-image-proxy
|
||||
# Then paste the workers.dev URL it prints below. NEXT_PUBLIC_ vars are
|
||||
# inlined at BUILD time — set them in Vercel/Cloudflare project settings.
|
||||
NEXT_PUBLIC_IMAGE_PROXY_URL=
|
||||
# Hostnames the proxy is allowed to fetch (comma-separated). Default covers
|
||||
# Runware's CDN. If your IMAGE_BASE_URL points at another provider, add that
|
||||
# provider's image host here so its URLs take the proxy path too. Anything
|
||||
# not listed stays on the direct fetch. Only matters when the URL above is set.
|
||||
NEXT_PUBLIC_IMAGE_PROXY_ALLOWED_HOSTS=im.runware.ai
|
||||
|
||||
# ---- 6. Analytics · Umami (optional — leave blank to disable) ------
|
||||
# Privacy-friendly, cookieless page-view stats — no Cookie consent banner.
|
||||
|
||||
Reference in New Issue
Block a user