Repository navigation
fix(deploy): nginx /autobot-api→http :8001 + connection_upgrade map, distribute SLM_SECRET_KEY, SLM build VITE_API_URL=/slm (#10378, #10400, #10435) - #10456
Merged
Conversation
Contributor
✅ SSOT Configuration Compliance: Passing🎉 No hardcoded values detected that have SSOT config equivalents! |
Applied Black, isort, and autoflake to match code-quality checks. Triggered by workflow auto-fix-formatting.yml. Co-Authored-By: Paperclip <noreply@paperclip.ing>
This was referenced Jun 22, 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.
Thinking Path
Three deploy-durability bugs where a live stopgap exists but the repo templates diverged. #10378: nginx
/autobot-api/proxied tohttps :8443(nothing listens; co-located backend ishttp :8001) and hardcodedConnection "upgrade"(breaks REST). #10400: backend→SLM service-JWT signed withAUTOBOT_JWT_SECRETbut SLM verifies withSLM_SECRET_KEY, never distributed → 4001. #10435: code-sync SLM-frontend rebuild ran plainnpm run buildwithoutVITE_API_URL→ vite guard hard-errors → silent stale dist.What Changed
autobot-slm.conf.j2— addedmap $http_upgrade $connection_upgrade;/autobot-api/co-located →http://autobot_backend/api/(uvicorn :8001), standalone honoursautobot_backend_protocol;Connectionnow$connection_upgrade.slm_manager/defaults/main.yml:autobot_backend_port8443→8001, addedautobot_backend_protocol: http.roles/backend/tasks/main.yml+backend.env.j2— backend role now readsSLM_SECRET_KEYfrom/etc/autobot/slm-secrets.envand setsbackend_jwt_secret(mirrors the fix(config): SLM_AUTH_TOKEN unset causes perpetual WebSocket 403 errors (4400+/day) #7689 SLM_AUTH_TOKEN read), soAUTOBOT_JWT_SECRET == SLM_SECRET_KEYevery deploy. Same read added toupdate-all-nodes.yml's direct-template path.role_registry.pypost_sync,slm_managertask,role.json.j2,update-node.yml) →build:slm+VITE_API_URL=/slm(removed the brokenVITE_API_URL=''conditional). User frontend untouched.Verification
python -m py_compilechanged .py → OK; yamllint/yaml.safe_loadon yml → OK; Jinja eyeballed (single-line, no>-folding).Follow-up (not blocking)
#10400 403-handshake originates before the FastAPI route (uvicorn proxy / WS path on non-loopback) — needs live repro; will file a follow-up. Also
update-all-nodes.ymlnever readSLM_AUTH_TOKEN(pre-existing #7689 gap) — follow-up candidate.Model Used
Claude Opus 4.8 (devops-engineer subagent).