- Decision
- ADR-246
- Date
- 2026-11-17
- Status
- AcceptedAccepted (owner, 2026-11-17: "fix the updater url"). Host-tested:
test-set-updater-url.sh(placeholder replaced, idempotent, upstream default not overwritten, five bad env files and a missing one refused) and four new cases oftest-check-required-packages.sh(upstream URL, placeholder, no URL, listed APK missing). The env file exists on the build host. Run on the builtstallionandlynximages of the build host: the gate reports no Updater complaint (it still reports the old images' Guardian and missing exit files, which predate ADR-240). Not run: a build that applies the published patch and then the script. - Mentions
- ADR-047, ADR-240, ADR-245
1Decision
Keep the URL of the private OTA server out of the repositories and still put it into every image (amends ADR-245, item 1). (1) tools/build/set-updater-url.sh <tree> [env-file] replaces the placeholder https://ota.example.invalid/ of the Updater's res/values/config.xml with OTA_URL from an env file that is never committed (default <build-root>/ota-url.env, mode 600, one line OTA_URL=https://<host>/).
It reads the variable by pattern and does not source the file, accepts only https://host/, refuses the placeholder and the upstream default as a value, leaves a tree that already holds the URL alone, and fails on a tree whose URL is neither. (2) check-required-packages.sh reads the URL from the built Updater.apk (resources.arsc) and fails an image that holds no https URL, the upstream default or a .invalid host.
2Why and evidence
A published patch must not carry the owner's host, and an image built from it must still update from the owner's server. A gate on the built APK catches a skipped step that no source check can see, as ADR-047 did for a skipped package.
3Consequences
A tree built from the published patches needs the script before the build; the landed tree of the build host already holds the real URL and is left alone. The gate fails every image whose Updater does not point at an https host other than the upstream default, so a different private host would pass it. The env file is the only copy of the URL outside the images; the owner keeps it.
4Review when
A build is made from a tree that the script has not touched; the Updater moves to another mechanism than config.xml; the owner publishes updates on a host that must be named in the repositories.
Read from docs/governance/decision-log.md, entry ADR-246.