feat: proxy path prefix and proxied dashboard support#68
Merged
Conversation
rusty4444
requested changes
Jul 2, 2026
rusty4444
left a comment
Owner
There was a problem hiding this comment.
Hermes Agent Review
Verdict: Changes requested.
I checked out the PR locally and ran:
flutter pub getflutter test test/connection_manager_test.dart— all 31 tests passedflutter analyze— no issues found
Blocking issue:
- lib/core/services/connection_manager.dart:560-567 —
DashboardClient._authHeaders()checks_usesPasswordAuthbefore_proxied, so a saved connection withdashboardProxied: trueand non-empty dashboard credentials will still call/auth/password-loginand send a session cookie. That contradicts the new UI copy (“Nginx injects auth — app sends clean requests”) and can break proxied deployments where auth is injected upstream. Please make proxied mode take precedence over password/open-dashboard auth, or prevent/purge dashboard credentials when proxied mode is enabled. Add a regression test coveringproxied: truewith non-emptyusername/password.
Non-blocking notes:
- Path-prefix URL normalization is covered by tests and looks good.
- Serialization/backward compatibility coverage for the new fields is good.
I did not merge this PR: it has no visible CI checks, and this automation only merges PRs with non-empty, all-successful status checks.
rusty4444
approved these changes
Jul 2, 2026
rusty4444
left a comment
Owner
There was a problem hiding this comment.
Hermes Agent Review
Approved after follow-up fixes.
I reviewed the updated PR and pushed a follow-up commit (a792965) that fixes the previously blocking proxied-auth issue and the remaining path-prefix call sites:
ChatScreennow passes the saved gateway path prefix toApiClient, so existing chat history and streaming completions use the proxy path.- API-key validation now uses the configured gateway prefix.
- Dashboard validation and all drawer screens now use dashboard prefix/proxied mode consistently.
- The Dashboard / Proxy settings dialog can edit gateway prefix, dashboard prefix, proxied mode, port, and credentials after a connection is created.
- README and version were updated for v1.0.8.
Verification run locally:
flutter pub getflutter analyze --fatal-infos— no issuesflutter test— all tests passedflutter build apk --release --split-per-abi— built all three release APKsapksigner verify --print-certs— all APKs signed with the stable Hermes Android release cert (SHA-2560710e9dfe1eef9ab15906433878d8c3dd14e141d554fc57b66acc7e4ced302a3)
No remaining blockers found.
rusty4444
added a commit
that referenced
this pull request
Jul 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for Hermes deployments behind a reverse proxy where the
Gateway API and Dashboard share the same host/port but sit under
different URL paths (e.g.
/profile/peter/v1/for chat,/dashboard/api/for dashboard).Changes
SavedConnection: new fieldsgatewayPrefix,dashboardPrefix,and
dashboardProxiedto configure custom API paths and proxy mode.joinBaseUrl(): normalizes a base URL with an optional pathprefix, used by both
ApiClientandDashboardClient.ApiClient: accepts optionalpathPrefixparameter so all RESTcalls (sessions, messages, health, chat completions) go through the
correct proxy path.
DashboardClient: acceptspathPrefixandproxiedparameters.When
proxiedis true, skips SPA session-token auto-discovery andsends clean HTTP requests — the proxy injects
Authorization: Bearer.UI: adds an "Advanced / Proxy Settings" collapsible section to
the connection dialog with fields for gateway path prefix, dashboard
path prefix, and a "Dashboard behind proxy" toggle.