[web] Self-hosted deployment: UI doesn't reflect server-side config + auth token exposure risk
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.4k
- Forks
- 365
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 169
Description
Context
I want to deploy @workflow/web to Vercel as a standalone observability dashboard that connects to workflows running in other projects. Environment variables are set in the Vercel project settings, and the UI should reflect this configuration without requiring URL params.
Problem
1. UI doesn't reflect server-side configuration
The client is unaware of server-side env vars, causing it to default to "Connected to: Local" even when WORKFLOW_TARGET_WORLD=vercel is set:
2. Documentation leads to a security pitfall
The README explains to set WORKFLOW_TARGET_WORLD=vercel for deployments on Vercel:
However, this is not sufficient which leads users to open the settings form and fill in the configuration (including auth token). Those values are then exposed in URL query params—visible in browser history, server logs, and referer headers.
Current Behavior
version: 4.0.1-beta.15
- ✅ Server actions correctly read env vars (API calls work)
- ❌ UI shows "Connected to: Local" regardless of env vars
- ❌ Settings form exposes auth token in URL when submitted
Workaround:
- Access via
/?backend=vercel—but this is undocumented. - Set
Backendtovercelvia the UI WITHOUT filling in any other fields—but this is undocumented.
Proposed Solution
- Update docs to clarify set up and warn users to not submit sensitive credentials when self-hosting.
- Pass server config to client with merge priority:
- URL query params (highest—for CLI compatibility)
- Env vars (for self-hosted deployments)
- Default values (fallback)
---> This way the backend is configured on initial load.
- Conditionally disable auth token input for remote backends
- When
backend=vercel: disable the token field and display a note indicating auth must be configured viaWORKFLOW_API_TOKENenv var - When
backend=local: keep the field enabled (local development doesn't carry the same URL exposure risk) - Alternatively, if the field must remain for edge cases, display a prominent warning.
- When
I would be happy to help with 2. and 3. if this approach aligns with the project's direction.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with packages/web/README.md and the @workflow/web configuration and settings form described in the issue. Trace how server environment variables and URL parameters reach the client, then verify that remote auth tokens are not placed in URL parameters and that the UI reflects the configured backend; document the self-hosted setup and security warning.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- documentation, frontend, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100