Repository navigation
Conversation
Add four OpenBao paths under secrets/semantic-router-dashboard-admin-*. The email is admin@<cluster domain>. The name is admin. The password and JWT signing key are random and write-once. Add an ExternalSecret that projects these paths into Secret semantic-router-dashboard-admin. It runs as a PreSync hook. Set dashboard.extraEnv to read the admin credentials from that Secret. Set dashboard.jwtSecret.existingSecret so sessions survive pod restarts. Set allowOpenBootstrap to false. The public first-admin form stays closed. Update the README dashboard access section. Refs EAI-9781 Co-authored-by: Cursor <cursoragent@cursor.com>
lauri-amd
left a comment
There was a problem hiding this comment.
I like the idea. A stable admin and a stable session key are clear improvements. My concern is coupling.
Why the OpenBao and ESO dependency matters
This blueprint is a root-extras component. It sits outside core on purpose, and it should be possible to run it on other clusters with little extra work. Today the dependencies are documented and have fallbacks. Gateway API and Envoy Gateway are standard. The AI Gateway parts are kept in aigw-extras/, and a direct-Envoy fallback exists.
This PR adds a hard dependency on two more components, OpenBao and External Secrets Operator, plus a ClusterSecretStore with the name openbao-secret-store. The dashboard login needs only one Kubernetes Secret, which is a small reason to add that dependency. It also changes what fails:
- The ExternalSecret is a PreSync hook. If the store is missing or unhealthy, the hook fails and the whole Application sync stops. That includes the router, not only the dashboard. On a cluster without OpenBao, the blueprint does not install at all.
- Before this change, a missing admin only meant that nobody could log in to the dashboard. The router still worked.
Proposal
As shipped, the dashboard has no admin, and allowOpenBootstrap stays false. The router works, but nobody can log in to the dashboard until the user picks one of these ways:
-
Startup admin from a Secret (any cluster). The chart reads Secret
semantic-router-dashboard-adminin thesemantic-routernamespace, with the keysemail,name,passwordandjwt-secret. Create it on the cluster before the first sync:kubectl -n semantic-router create secret generic semantic-router-dashboard-admin \ --from-literal=email=admin@<your domain> \ --from-literal=name=admin \ --from-literal=password="$(openssl rand -hex 16)" \ --from-literal=jwt-secret="$(openssl rand -hex 32)"
Do not put it in the overlay repo, because the repo would then contain the password in plain text.
-
Startup admin from OpenBao (bloomed EAI cluster). This is the same as way 1, but ESO creates the Secret instead of
kubectl. Fetchdashboard-admin-externalsecret.yamlinstead of running the command above. The values come from the four rows that this PR adds toopenbao-config, so they are always present on a bloomed cluster. -
Open bootstrap (short demo only). Set
allowOpenBootstrap: trueand create the admin in the web form. The form is public and has no authentication until an admin exists. Turn it off again after you create the admin. Do not use this on a cluster that stays up.
Ways 1 and 2 both use the same extraEnv and jwtSecret.existingSecret values from this PR. In values.yaml, ship those values commented out, with a note that they are for ways 1 and 2. If they are always on and the Secret is missing, the dashboard pod stops in CreateContainerConfigError.
Changes to the PR
- Keep
allowOpenBootstrap: falseas the default. - Keep the ExternalSecret in this blueprint, next to the other manifests. Remove it from the default
curllist, and mark it as optional in the file table. - Replace "Dashboard access" with the three ways, in the order above. Give the
curlcommand for the ExternalSecret only in way 2. Say that the file is necessary only to get the Secret from OpenBao. - In Prerequisites, list OpenBao, ESO and
ClusterSecretStore/openbao-secret-storeas needed only for way 2. A bloomed cluster has all three. - Keep the four rows in
openbao-config.
A smaller point
Use a negative argocd.argoproj.io/sync-wave on the ExternalSecret instead of a PreSync hook. Argo CD does not track hook resources for pruning or self-heal. With the default BeforeHookCreation policy, Argo CD deletes and recreates the ExternalSecret on each sync, and creationPolicy: Owner deletes the Secret with it. A sync wave gives the same order without these problems.
Copy the blueprint into the cluster-values repository. Merge only the semantic-router key in extra-apps-values.yaml. Read the cluster domain from kubectl, then commit and push. Create the client-key Secret when that Secret is absent. Co-authored-by: Cursor <cursoragent@cursor.com>
Point the chart and both image tags at the tested commit. Move decisions under recipes. Shorten the comments in the files the install script copies. Co-authored-by: Cursor <cursoragent@cursor.com>
Lead the blueprint README with scripts/setup.sh. Name the overlay fields for a real model and Service. Point the extra-components page and the examples at those sections. Co-authored-by: Cursor <cursoragent@cursor.com>
Add a Cursor rule that asks for short comments and leaves out a finished migration. Co-authored-by: Cursor <cursoragent@cursor.com>
cluster-bloom writes key DOMAIN in ConfigMap cluster-domain. The manual install guide writes key domain. The script now reads domain when DOMAIN is empty. Document the fallback in scripts/README.md. Refs EAI-9781 Co-authored-by: Cursor <cursoragent@cursor.com>
The OpenBao paths for the dashboard admin come from openbao-config in the same cluster-forge release. Without those paths, the PreSync ExternalSecret does not become healthy and the sync does not finish. Refs EAI-9781 Co-authored-by: Cursor <cursoragent@cursor.com>
Accept any RFC 1123 host name as the cluster domain, and change it to lowercase. This includes punycode and single-label domains. Remove the sed escaping, because the domain can no longer contain those characters. Push on each run. A first push that fails no longer stops a second run from pushing the commit and creating the API key Secret. Describe the blueprint path without the internal variable name. Refs EAI-9781 Co-authored-by: Cursor <cursoragent@cursor.com>
Shorten the file headers in values.yaml, gateway-routing.yaml, the admin ExternalSecret, and the OpenBao definitions to two sentences. Remove the wrong path prefix from the ExternalSecret header. Replace "greenfield" and "wired up" with Simplified Technical English. Refs EAI-9781 Co-authored-by: Cursor <cursoragent@cursor.com>
|
Great feedback, thanks @lauri-amd ... will keep draft till this tight coupling is resolved 💟 |
The dashboard starts without an admin Secret. The ExternalSecret is optional and uses sync wave -1 instead of a PreSync hook. Gateway routes, backends and quota now render from the three models in values.yaml. The README documents the three admin login options. Co-authored-by: Cursor <cursoragent@cursor.com>
Add setup-dashboard-admin.sh. It copies the OpenBao ExternalSecret into the chart and enables dashboard.jwtSecret and dashboard.extraEnv. Let setup.sh push with GITEA_USERNAME and GITEA_PASSWORD when both are set. Update the blueprint README and the scripts README. Co-authored-by: Cursor <cursoragent@cursor.com>
Add four OpenBao paths under secrets/semantic-router-dashboard-admin-*. The email is admin@. The name is admin. The password and JWT signing key are random and write-once.
Add an ExternalSecret that projects these paths into Secret semantic-router-dashboard-admin. It runs as a PreSync hook.
Set dashboard.extraEnv to read the admin credentials from that Secret. Set dashboard.jwtSecret.existingSecret so sessions survive pod restarts. Set allowOpenBootstrap to false. The public first-admin form stays closed.
Update the README dashboard access section.
Refs EAI-9781