Skip to content

K2GO-444 refactor: ship code_addons as an overlay - #620

Merged
luisguzman-adfa merged 1 commit into
mainfrom
refactor/K2GO-444-code-addons-overlay
Oct 3, 2026
Merged

luisguzman-adfa merged 1 commit into
mainfrom
refactor/K2GO-444-code-addons-overlay

Conversation

@luisguzman-adfa

Copy link
Copy Markdown
Collaborator

Carry the code_addons role as a whole-file overlay
(tools/upstream-patches/overlays/roles/code_addons/), like code_assets, instead
of a unified-diff patch. The patch edited two upstream-owned files (the
6-generic-apps include and vars/default_vars.yml); an upstream change to either
can make it drift and apply wrong with no crash, shipping a box with no add-ons
gallery.

Changes:

  • Move roles/code_addons/* from patches/0004-code-addons-add-role.patch to the
    overlay; delete the patch. The two upstream edits are dropped.
  • iiab-android bake: run the role via runrole code_addons post-install, gated
    for Standard and Full (Basic off), mirroring the code_assets step. An overlay
    cannot add the include, so the main install no longer auto-runs the role.
  • Update ADR-addons-offline-gallery.md to the overlay + runrole model.

Behavior: an add-ons mirror failure is now non-fatal at bake (|| warn), like
code_assets.

Verification: bash -n on the bake; apply-upstream-patches.sh --dry-run
enumerates roles/code_addons/* as an overlay; mirror_addons.py reproduced
byte-identical. Device test pending on a fresh bake: confirm
http://box:8085/code-addons/ serves and the catalog loads.

Carry the role as a whole-file overlay like code_assets, not a unified-diff
patch that edits two upstream files (6-generic-apps include, default_vars.yml)
and can drift silently, shipping a box with no gallery. The overlay adds only
new files, so nothing drifts. An overlay cannot add the include, so the main
install no longer auto-runs the role; the bake runs it via runrole code_addons
for Standard and Full, mirroring the code_assets step. Update the ADR.
@luisguzman-adfa
luisguzman-adfa merged commit 9d597cb into main Oct 3, 2026
@luisguzman-adfa
luisguzman-adfa deleted the refactor/K2GO-444-code-addons-overlay branch October 3, 2026 00:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant