Skip to content

many: allow bootc#18

Draft
supakeen wants to merge 3 commits intomainfrom
bootc-ref
Draft

many: allow bootc#18
supakeen wants to merge 3 commits intomainfrom
bootc-ref

Conversation

@supakeen
Copy link
Copy Markdown
Member

@supakeen supakeen commented Sep 23, 2025

image-builder >= 34 contains experimental support for building a subset of image types from bootable containers. Let's allow passing these options along through the plugin. Note that not all of these arguments have made it into image-builder yet so this will stay draft for a while.


Using this option will mean that the builder needs access to where the bootable container reference(s) are to be pulled from. I'll also have to figure out how to integrate this with pungi (which would/should probably build the container even though I don't think that's the case right now for bootable containers specifically).

Building bootable containers into disks in Koji implies that they are to be distributed to users, this means that the containers must include provisioning tools to be used at first boot as the containers will (hopefully) not contain any credentials.

@supakeen
Copy link
Copy Markdown
Member Author

supakeen commented Sep 23, 2025

Draft since I want to include this in tests and the container image needs to be pulled separately and we need to wait for image-builder releases that contain all flags.

It's probably also wise to await the ISO work and changes.

@supakeen supakeen force-pushed the bootc-ref branch 5 times, most recently from 1a093b9 to 2b75fb8 Compare September 26, 2025 06:01
`image-builder >= 34` contains experimental support for building a
subset of image types from bootable containers. Let's allow passing
these options along through the plugin.

Using this option will mean that the builder needs access to where the
bootable container reference is to be pulled from. It also implies that
`podman` is installed in the build root.

Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
For some bootc image types (installers) it is potentially possible to
set a payload reference that is embedded onto the ISO. Let's map that
into the plugin as well.

Signed-off-by: Simon de Vlieger <cmdr@supakeen.com>
Use a loop instead of each one separately.

Signed-off-by: Simon de Vlieger <cmdr@supakeen.com>
# available so there's an option to set it explicitly
bootc_default_fs = bootc.get("default-fs")
if bootc_default_fs:
cmd.extend(["--bootc-defaultfs", bootc_default_fs])
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option is called --bootc-default-fs.

for ref in ["ref", "build-ref", "installer-payload-ref"]:
bootc_ref = bootc.get(ref)
if bootc_ref:
cmd.extend(["--bootc-ref", bootc_ref])
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs to match the type of ref. maybe a map or a tuple to associate the cmdline argument with the bootc field.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch I had very recently updated this to do a loop and then pushed and forgot. Luckily tests are also failing

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.

2 participants