You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(branding): customize login page title and logo via env vars (#3773) (#3781)
* feat(branding): customize login page title and logo via env vars (#3773)
Add CUSTOM_TITLE and CUSTOM_LOGO_URL environment variables so operators
deploying MeshMonitor for a community/organization can rebrand the login
page without forking and rebuilding the image.
- environment.ts: parse both vars; validate CUSTOM_LOGO_URL scheme
(http(s)/data:image/relative only, rejecting javascript: etc.)
- authRoutes /status: expose branding (null when unset) pre-auth so the
login page can read it
- AuthContext: optional customTitle/customLogoUrl on AuthStatus
- LoginPage: render custom logo image + title, falling back to the
built-in SVG and "MeshMonitor" heading when unset
- docs + .env.example: document the new variables
- tests: cover default/null, set values, and unsafe-scheme rejection
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011JEaCGwY9Wz8jeV4e22GW4
* address review: drop stray files, reject SVG data URIs, tighten types/tests
- Remove three unrelated files that `git add -A` swept into the branch
(.claude/agent-memory/* and docs/internal/dev-notes/MCP_SERVER_PLAN.md)
- CUSTOM_LOGO_URL: reject data:image/svg+xml (SVG can embed scripts);
whitelist raster data: URIs (png/jpeg/gif/webp/avif) only
- AuthStatus.customTitle/customLogoUrl are now non-optional (string | null)
to match the runtime guarantee that /status always sends them
- Add edge-case tests: whitespace-only title, SVG data URI rejected,
raster data URI accepted
- Docs/.env.example note the SVG exclusion and relative-path origin
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011JEaCGwY9Wz8jeV4e22GW4
* address review: remove branch-only stray files from PR
These were untracked working-tree artifacts at branch creation that a
prior `git add -A` swept in. Untrack them (kept on disk locally).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011JEaCGwY9Wz8jeV4e22GW4
* address review: drop redundant client-side trim on branding values
The server already trims and normalizes CUSTOM_TITLE/CUSTOM_LOGO_URL
(null when unset), so the client-side .trim() was dead code.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011JEaCGwY9Wz8jeV4e22GW4
---------
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: docs/configuration/index.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -194,6 +194,15 @@ See the [Push Notifications guide](/features/notifications) for setup instructio
194
194
195
195
**Note**: `LOG_LEVEL` controls log output independently of `NODE_ENV`. This lets you enable debug logging in production Docker deployments without changing rate limits, cookie warnings, or other `NODE_ENV`-dependent behavior.
196
196
197
+
### Branding Variables
198
+
199
+
| Variable | Description | Default |
200
+
|----------|-------------|---------|
201
+
| `CUSTOM_TITLE` | Overrides the "MeshMonitor" heading on the login page | `MeshMonitor` |
202
+
| `CUSTOM_LOGO_URL` | Overrides the login-page logo with your own image (http(s), raster `data:image` — png/jpeg/gif/webp/avif, or same-origin relative URL) | built-in SVG |
203
+
204
+
**Note**: Both are optional and apply only to the login page. When unset — or when `CUSTOM_LOGO_URL` uses an unsupported scheme such as `javascript:` or a `data:image/svg+xml` URI (rejected because SVG can embed scripts) — MeshMonitor falls back to the default title and logo. Relative paths are resolved against the server's own origin.
0 commit comments