Skip to content

ephemeral: Add Ignition config injection support#232

Open
gursewak1997 wants to merge 1 commit intomainfrom
add-ignition-support
Open

ephemeral: Add Ignition config injection support#232
gursewak1997 wants to merge 1 commit intomainfrom
add-ignition-support

Conversation

@gursewak1997
Copy link
Collaborator

Add support for injecting Ignition configuration files into ephemeral 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.

Implementation:

  • Architecture-specific config delivery per FCOS docs:
    • x86_64/aarch64: fw_cfg at opt/com.coreos/config
    • s390x/ppc64le: virtio-blk with serial 'ignition', readonly
  • Runtime architecture detection for correct method
  • Image validation via labels (coreos.ignition or com.coreos.osname)
  • Added readonly support for virtio-blk devices
  • Test coverage for fw_cfg functionality

The config is successfully passed to the guest (verified via /sys/firmware/qemu_fw_cfg/). Ignition will process it on first boot. For ephemeral testing with pre-built FCOS images, Ignition skips as expected (subsequent boot behavior).

Useful for custom bootc images with Ignition (see bootc initramfs docs) and future to-disk workflows.

Closes: #228

Copy link

@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 adds support for injecting Ignition configuration files into ephemeral VMs. The implementation correctly handles different injection methods for various architectures (fw_cfg for x86_64/aarch64 and virtio-blk for s390x/ppc64le). The changes include updates to QEMU configuration, command-line options, and logic to detect Ignition support in images.

My review includes a couple of suggestions to improve code clarity, reduce duplication, and enhance performance. Specifically, I've recommended refactoring the virtio-blk device addition methods for better maintainability and optimizing the Ignition support check to be more efficient.

@gursewak1997 gursewak1997 force-pushed the add-ignition-support branch from dbfdfe3 to e74f5fd Compare March 20, 2026 23:04
Add support for injecting Ignition configuration files into ephemeral
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.

Implementation:
- Architecture-specific config delivery per FCOS docs:
  * x86_64/aarch64: fw_cfg at opt/com.coreos/config
  * s390x/ppc64le: virtio-blk with serial 'ignition', readonly
- Runtime architecture detection for correct method
- Image validation via labels (coreos.ignition or com.coreos.osname)
- Added readonly support for virtio-blk devices
- Test coverage for fw_cfg functionality

The config is successfully passed to the guest (verified via
/sys/firmware/qemu_fw_cfg/). Ignition will process it on first boot.
For ephemeral testing with pre-built FCOS images, Ignition skips as
expected (subsequent boot behavior).

Useful for custom bootc images with Ignition (see bootc initramfs
docs) and future to-disk workflows.

Closes: #228

Assisted-by: Claude Code (Sonnet 4.5)
Signed-off-by: gursewak1997 <gursmangat@gmail.com>
@gursewak1997 gursewak1997 force-pushed the add-ignition-support branch from e74f5fd to 7be5f96 Compare March 20, 2026 23:05
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

1 participant