Adds installer/Containerfile (a separate Anaconda-webui environment container, distinct from the quine-linux OS image) plus build-installer-image/build-installer-iso tasks that drive bootc-image-builder's bootc-installer type against it. Lets a forked/ patched anaconda-webui (built via COPR) get baked into the install ISO instead of stock Fedora's. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
4 KiB
Patched Anaconda installer
How to get a forked/patched Anaconda into the install ISO, instead of the stock Fedora one.
Why this needs a second container
task build-iso (the existing task) builds the ISO straight from RPMs via
bootc-image-builder's iso type -- there's no separate place to inject a
custom Anaconda build.
bootc-image-builder's bootc-installer type is different: it takes two
containers -- an "installer environment" container that has Anaconda
installed in it, and (via --bootc-installer-payload-ref) the actual OS to
install. The installer environment is just a container you build with a
Containerfile, so that's the hook: build your own installer image with
your patched Anaconda dnf installed instead of Fedora's, and point
bootc-image-builder at it.
installer/Containerfile in this repo is that installer environment. It's
unrelated to the quine-linux OS image built by the root Containerfile --
Anaconda only exists in this side container, never in the installed system.
Which Anaconda to fork
Fedora's anaconda package resolves to one of two UIs depending on the
image's release-identity package: anaconda-gui (old GTK hub-and-spoke) on
server/basic/IoT identities, anaconda-webui (Cockpit + React/PatternFly)
everywhere else. All current upstream feature work happens on the WebUI, so
that's the one to fork:
- https://github.com/rhinstaller/anaconda-webui, forked to https://github.com/philip-peterson/anaconda-webui
installer/Containerfile depends on anaconda-webui explicitly (not just
the bare anaconda metapackage) so the UI doesn't depend on incidentally
matching a release-identity package.
Workflow
- Fork
rhinstaller/anaconda-webuitophilip-peterson/anaconda-webuion GitHub, make your panel/control changes there. - Get it built as an RPM your installer container can
dnf install. Recommended: a Fedora COPR project.- Create the COPR project
philip-peterson/quine-anaconda-webui(https://copr.fedorainfracloud.org/), point it atphilip-peterson/anaconda-webui(branch or a webhook), let COPR build it against the Fedora release Aurora currently tracks. - That name is already wired in as the
COPR_REPOdefault inTaskfile.ymlandinstaller/Containerfile. Using a different COPR project name means overridingCOPR_REPO=on thetaskinvocations below instead. - This publishes your fork's source and build logs on COPR's infrastructure (marking a project "unlisted" hides it from browsing, not from direct access) -- worth knowing before you push anything you wouldn't want visible outside this machine.
- Create the COPR project
- Build the installer image and ISO:
This builds the quine-linux OS image (if needed), buildstask build-installer-isoinstaller/Containerfilewith thephilip-peterson/quine-anaconda-webuiCOPR repo enabled, and producesoutput/bootc-installer/install.iso. - Iterate: push a change to your fork, wait for COPR to rebuild, rerun
task build-installer-iso-- podman/task will rebuild the installer layer to pick up the new RPM.
Local alternative (no COPR)
If you'd rather not publish the fork anywhere: build the RPM locally with
mock targeting the same Fedora release/arch as the installer base,
createrepo_c the output into a directory, and either bind-mount that
directory into installer/Containerfile's build context and add it as a
file:// repo, or drop the built RPMs into a dnf localinstall step. This
avoids any external service but means keeping the mock chroot's Fedora
release in sync with the installer base by hand.
Caveats
anaconda-webui's package/dependency structure moves with each Fedora release; ifdnf install anaconda-webuistarts failing, check whatanaconda.spec.inin your fork currently requires.- The installer environment's Fedora release should stay close to whatever
release the actual
quine-linuximage (and thus the ISO's kernel/dracut) is built against, to avoid mismatches between the boot environment and the installed system.