Repository navigation
refactor: drive headless validators via the static runtime override - #24
Merged
Merged
Conversation
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
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.
Summary
Closes #23
Follow-up to #21: the headless-validator mechanism was the last place generating YAML from JS
(
writeGeneratedOverridestring-building.generated/service-overrides.yamlon every run). It nowrides the same static, env-var-driven override as the SV UIs, so there is a single mechanism and no
YAML codegen anywhere.
Changes
templates/runtime-overrides.yamlgains one mount per validator with a fixed, readable target:${APP_*_NGINX_ROUTES}:/etc/nginx/templates/<name>.conf.template. The env var selects the source:Splice's real routing config when
ui: true(identical to vanilla after compose dedups the mount),or an empty
.generated/empty-nginx-routes.confwhen the validator is headless or disabled.writeGeneratedOverrideand.generated/service-overrides.yamlremoved;writeLocalnetEnvwritesthe
APP_PROVIDER_NGINX_ROUTES/APP_USER_NGINX_ROUTESvars instead.scripts/runtime-plan.test.js; docs and template commentsupdated.
fix(smoke): pre-existing breakage onmain— feat: wire sv web UI flags to runtime via static override #21 shipped the scaffoldedsvdefaults as all-off,but
smoke.jsstill asserted all-on, sonpm run test:e2efailed. Assertions aligned.Acceptance criteria
templates/runtime-overrides.yamlvia env vars, with behavioridentical to today (backend reachable on direct ports, no nginx routes, nginx boots).
writeGeneratedOverrideand.generated/service-overrides.yamlare removed, along with theconditional
-fwiring indockerComposeArgs.splice-localnet-overrides.yamlheader.runtime-plan.test.js) and verified against a live stack with a headless and aUI-enabled validator.
Note: the issue sketched Splice's
.c${VAR}f.templatefilename trick; implemented with a clearerequivalent — fixed mount target, env var selects the source file — avoiding the cryptic on/off
concatenation.
Test plan
Automated tests
scripts/runtime-plan.test.js— route-source env contract (empty file for headless/disabled,Splice's real config for
ui: true).npm test(26 passing);npm run test:e2efor the smoke test (fixed here).Manual verification
Against the live stack: with
appUser.ui: true, wallet and ANS serve 200 on port 2000; withui: false, no UI containers run, port 2000 refuses connections, the renderedapp-user.confinsidenginx is 0 bytes, and the backend answers 200 on its direct port (:2975). nginx boots in every
combination, including all SV UIs and all validator UIs off simultaneously.
Breaking changes
None.
Checklist
Screenshots
None.