mirror of
https://github.com/dograh-hq/dograh.git
synced 2026-06-22 08:38:13 +02:00
* fix(ui): proxy WebSocket signaling upgrade so local web calls work (#425) 1.34.0 replaced the next.config `/api/* -> BACKEND_URL` rewrite with the Route Handler `api/v1/[...path]/route.ts`. Route Handlers proxy HTTP fine (so `/api/v1/*` still 200s) but cannot upgrade WebSocket connections. The removed *rewrite* used to carry the upgrade, so without it the signaling socket (`/api/v1/ws/signaling/...`) has no proxy path and every local web call dies before WebRTC negotiation — the symptom reported in #425. nginx would proxy the upgrade but only runs in the `remote` compose profile, so local OSS deployments have nothing to carry it. Re-add a `beforeFiles` rewrite scoped to `/api/v1/ws/:path*` so the upgrade is proxied to the backend *before* the `[...path]` Route Handler can swallow it. HTTP `/api/v1/*` is untouched and still flows through the Route Handler (auth/cookie handling intact). Verified on a 1.34.0-derived source build: signaling WS now reports `[accepted]` / `connection open` server-side and `WebSocket connected` + `ICE connection state: connected` client-side; WebRTC negotiates end-to-end. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(ui): use direct localhost WebSocket signaling --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: Abhishek Kumar <abhishek@a6k.me> |
||
|---|---|---|
| .. | ||
| public | ||
| scripts | ||
| src | ||
| .dockerignore | ||
| .env.example | ||
| .gitignore | ||
| .pre-commit-config.yaml | ||
| AGENTS.md | ||
| CLAUDE.md | ||
| components.json | ||
| Dockerfile | ||
| eslint.config.mjs | ||
| next.config.ts | ||
| openapi-ts.config.ts | ||
| package-lock.json | ||
| package.json | ||
| postcss.config.mjs | ||
| README.md | ||
| sentry.edge.config.ts | ||
| sentry.server.config.ts | ||
| tsconfig.json | ||
This is a Next.js project bootstrapped with create-next-app.
Getting Started
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
Login Flow
- The redirection happens server side using
ui/src/stack.tsxafter the user has logged in.
Sentry and PostHog
- Initialized in
ui/src/instrumentation-client.ts