Repository navigation
K2GO-437 feat(code-assets): serve Code on the Go build assets offline at /code-assets - #619
Merged
Merged
Conversation
… at /code-assets Mirror the release build set (Gradle, SDK, bootstrap, Maven repo, docs, templates) into /library/www/code-assets with a browse page, served on the LAN so a device can set up Code on the Go with no internet. Role ships as an overlay, baked on Full via runrole; dash-node drives an incremental "Update build assets" refresh (dash-node 1.3.10).
Installing (runrole) and browsing (WebView) code_assets do not use the /code-assets/refresh endpoints; only the "Update build assets" action does, and it degrades to a 404 -> "could not update" on an older dash-node. So installing and viewing are no longer blocked by DashNodeGate on the dash-node version.
Migrate the 11 code_assets UI strings from strings_untranslated.xml into strings.xml and add translations to all 33 language locales, so MissingTranslation is satisfied and the tracker is empty. Translations are machine-generated, pending human review; Yoruba (yo) and Swahili (sw) are the roughest and most worth a check.
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.
What
Serve Code on the Go's release build environment (9 brotli assets, ~0.78 GiB)
offline on the box LAN at
/code-assets, parallel to/code-addons. A device onthe box network can set up CoGo with no internet.
Why
A fully offline box must provide the CoGo build env locally. The assets live at
appdevforall.org/dev-assets/release/(per-file.md5, no index), moving to R2soon, so the source base is a single swappable variable.
Changes
code_assets(overlay intools/upstream-patches/overlays/): manifest-drivenmirror_code_assets.pydownloads each asset, verifies against its sibling.md5,writes an
.md5sidecar, reuses unchanged files by md5 (--reuse-from, short-circuitsup-to-date), and generates a self-contained browse page (cards, light/dark, favicon +header logo). nginx serves
.br/zip/jar asapplication/octet-stream(noContent-Encoding) and
.md5as text/plain.iiab-androidenables the role on*_large*and runsrunrole code_assetspost-install (non-fatal). The role tree ships on every tier viathe overlay, so on-demand install works anywhere; only Full bakes it.
/code-assets/refresh(start/status/cancel) +code-assets-refresh.shwrapper. Install and browsing do NOT depend on the dash-node version; only the "Update
build assets" action uses the refresh endpoint and degrades gracefully on older builds.
/code-assetsmodule card + action-sheet/detail "Update build assets" (clone ofadd-ons), Home card, generic
/code-assets/navigation. 11 new strings localized to all33 locales.
controller/docs/ADR-code-assets-offline-build-env.md.Scope / not included
CoGo has no runtime asset URL today (release APK bundles the build env at build time).
A CoGo-side runtime downloader with a configurable base URL is a separate future change.
Verification
:app:assembleStandardDebuggreen; aapt resource merge green (33 locales).generated the page, installed the nginx conf;
/code-assetsserves 200,.brreturnsapplication/octet-streamwith no Content-Encoding; browse page renders in the in-appWebView (light/dark).