-
Notifications
You must be signed in to change notification settings - Fork 129
Description
The composefs-rs project is a Rust implementation of composefs that is capable of generating composefs images from container images.
We should integrate it in bootc as an alternative to the ostree backend. This would help make progress on phasing out ostree, UKI support and unified storage:
To be able to do that, we need to make bootc capable of handling both repository formats and have it handle the transition from ostree to pure composefs.
A potential layout for this is discussed in containers/composefs-rs#38.
Here are suggested steps for creating a first proof of concept implementation:
- Add an option to bootc switch
bootc switch --composefs quay.io://foo:bar
- bootc will import the container image using the composefs-rs library in a dedicated composefs repo
- bootc will set up the repo as needed
- bootc will create a new "deployment" for this image
- Do the three way merge for /etc, comparing previous image, new image, current changes
- Or use overlayfs instead to do that for /etc
- Setup /var so that it's shared with ostree deployments
- bootc will setup the new deployment for the next boot
- UKI case:
- GRUB: Generate GRUB config snippet to boot the UKIs in order
- systemd-boot: Install the UKI in /boot/efi/EFI/Linux (order handling to be confirmed)
- Non-UKI case:
- GRUB: Install the kernel & initrd in /boot and setup the BLS config
- systemd-boot: Install the kernel & initrd in /boot/efi and setup the BLS config
- UKI case:
Tracker issues:
- @cgwalters factor out issue for what gates merging the composefs branch to main
- Determine path for GRUB fragment writing; one possibility is to write BLS like entries even for UKIs, and then generate grub fragments from them
- Fix
default_t
after install - boot: Empty /sysroot too containers/composefs-rs#169 - @cgwalters fix lost commits since c89efab ( composefs: Add missed commits when rebasing #1502 )
- @cgwalters Refactor branch to use composefs repo from storage
- @cgwalters Add
bootc storage init-composefs
to initialize a repo from existing system - Service similar to
ostree-finalize
, saycomposefs-native-finalize
which will be responsible for atomically swapping staged and current boot entries among other things. - @Johan-Liebert1
/etc
merge: /etc & 3 way merge vs overlayfs for composefs native integration #1469 ( Initial implementation for /etc merge #1485 ) - @Johan-Liebert1 Copy initramfs code (mount) from composefs-rs into bootc initramfs
- @jeckersb Sealed image build UX + implementation #1498
- [ ]
- Detect UKIs and automatically enable composefs backend
- Document + examples + CI setting up UKIs from current fedora/centos bootc (ref examples: Add bootc UKI & BLS examples containers/composefs-rs#143 )
Install UX
Right now we're adding a new --composefs-native
.
Proposal: Sealed images default to requiring sealed setup
i.e. secure boot w/fsverity on target or erroring by default
(less agreement on: can opt in to degrading w/ bootc install <image> --disable-sealing
)
TODO: Create a spec for detecting sealed images
- Detect via looking at layer structure
- Detect by parsing UKI
Proposal: Automatically detect in initramfs if Secure Boot is disabled
?
Proposal from @travier: Remove verity optional composefs flag
Some confusion about use cases