Skip to content

libvirt: Add Ignition config injection support#245

Merged
cgwalters merged 1 commit intomainfrom
add-ignition-libvirt
Apr 8, 2026
Merged

libvirt: Add Ignition config injection support#245
cgwalters merged 1 commit intomainfrom
add-ignition-libvirt

Conversation

@gursewak1997
Copy link
Copy Markdown
Collaborator

Add support for injecting Ignition configuration files into libvirt VMs via QEMU's fw_cfg mechanism (x86_64/aarch64) and virtio-blk (s390x/ppc64le). This enables first-boot provisioning for bootc-based systems that use Ignition, matching the ephemeral implementation.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces Ignition configuration injection for libvirt VMs, enabling first-boot provisioning via a new --ignition CLI flag. The changes include architecture-specific injection (fw_cfg for x86_64/aarch64 and virtio-blk for s390x/ppc64le), persistent storage of config files in libvirt pools, automated cleanup, and new integration tests. Review feedback identifies a bug where image inspection is attempted before the image is pulled, a mismatch in the PowerPC architecture string, and a potential failure in XML metadata lookup for nested elements.

@gursewak1997 gursewak1997 force-pushed the add-ignition-libvirt branch from c6becee to 825bf0e Compare April 7, 2026 22:37
@gursewak1997 gursewak1997 marked this pull request as ready for review April 7, 2026 22:37
Add support for injecting Ignition configuration files into libvirt
VMs via QEMU's fw_cfg mechanism (x86_64/aarch64) and virtio-blk
(s390x/ppc64le). This enables first-boot provisioning for bootc-based
systems that use Ignition, matching the ephemeral implementation.

Signed-off-by: gursewak1997 <gursmangat@gmail.com>
@gursewak1997 gursewak1997 force-pushed the add-ignition-libvirt branch from 825bf0e to abe3227 Compare April 7, 2026 23:50
// Configure Ignition injection based on architecture
let arch = std::env::consts::ARCH;
match arch {
"x86_64" | "aarch64" => {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Maybe useful to have a const IGN_FWCFG_ARCHES that's shared here and with others

ignition_persistent_path.to_string(),
);
}
"s390x" | "powerpc64le" => {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Similarly const IGN_VIRTIO_BLK_ARCHES?

@cgwalters cgwalters merged commit b9f330e into main Apr 8, 2026
19 checks passed
@gursewak1997 gursewak1997 deleted the add-ignition-libvirt branch April 8, 2026 19:08
@gursewak1997 gursewak1997 linked an issue Apr 8, 2026 that may be closed by this pull request
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.

Add support for injecting Ignition

2 participants