ci: make image building slightly more reproducible within the pipeline

Since we don't have binary repo snapshots in Alpine/pmOS for all branches, this adds a new job in the image building pipeline to collect all packages from all device+ui combos that will be built, downloads them all with apk fetch, then creates a custom repo, and instructs mkosi to install only from that repo.

There are some limitations/exceptions to this approach:

  1. the mkosi tools image will be built by whatever is in the current binary repos, there doesn't seem to be a knob to tell it to use the pkg cache only. This is probably fine and low risk. The "tools image" is analogous to pmbootstrap's "native" chroot. The contents aren't in the final image, it just runs stuff to build the final image.

  2. pmos-install-recommends packages aren't cached ahead of time... ideally we'd not use install-recommends at all (see #32). This will help us support snapshotting packages pulled in by install-recommends: postmarketos-install-recommends!5 (merged) Fixed.

Edited by Clayton Craft

Merge request reports

Loading