Skip to content

Conversation

@jeckersb
Copy link
Collaborator

Rebirth of #1533 targeting
main after the composefs-backend branch was merged.

@bootc-bot bootc-bot bot requested a review from henrywang September 15, 2025 20:08
@jeckersb jeckersb marked this pull request as ready for review September 15, 2025 20:40
test:
- /tmt/tests/test-24-local-upgrade-reboot

/test-26-examples-build:
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I'm not totally sold on testing this way. This was the result of asking claude to write a test to make sure the examples build. Is it too heavyweight to go through the matrix of spawning VMs with tmt just to sanity check the examples work?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

(At the very least if we do it via tmt we need to add it to the list of tests in the github workflow)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

(At the very least if we do it via tmt we need to add it to the list of tests in the github workflow)

I added this at least for the moment just to see it run and see what happens...

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes, it's messy to build containers inside a tmt test, and we definitely want to make it easy to build it outside of such a test too.

But OTOH, I think it's totally fine to do it this way as is right now. BTW though this will just conflict with #1607 - what we're going to need to do is at least have a separate tmt "plan" for tests which are testing booting via bootc vs testing the build side.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Well first order of business...

./tmt-test-wrapper-inner.sh-tmt-tests-test-26-examples-build-1-default-0-default-0: line 6: cd: examples/bootc-bls: No such file or directory

Guess it's time to learn what path tomfoolery is going on in tmt

Copy link
Collaborator Author

@jeckersb jeckersb Sep 16, 2025

Choose a reason for hiding this comment

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

Maybe also a good point to go on a side quest and finally learn what nushell is all about...

Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm kind of regretting nushell a bit because IME ai models are more likely to confabulate with it. But writing nontrivial amounts of bash sucks.

One issue is TMT really pushes for having tests be interpreted code, but maybe we could mitigate that. There's obviously a ton of interpreted options, from python to ansible.

Ideally though for me, tests are like production code:

But anyways for what's going on here, bash is probably OK...

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah it was less "rewrite this tiny bash snippet in nushell" and moreso "most everything else is in nushell so I should probably at least understand how everything else works"

--security-opt label=type:unconfined_t \
"${IMAGE}" \
bootc install to-disk \
--composefs-native \
Copy link
Collaborator

Choose a reason for hiding this comment

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

Right now bcvk doesn't allow passing arbitrary flags; we can add that of course, but I do think we should be aiming to move this to an install flag or autodetection instead.

@jeckersb
Copy link
Collaborator Author

Added some commits here, tried to break it up so everything was self-explanatory in its intentions. Tests are finally passing for me locally so I suspect this should pass and be ready for review.

@jeckersb
Copy link
Collaborator Author

Hm looks like 051-test-initramfs.nu failed?

@jeckersb
Copy link
Collaborator Author

Hm looks like 051-test-initramfs.nu failed?

19:42:30                 out: TAP version 14
19:42:30                 out: initramfs
19:42:30                 out: -- No entries --
19:42:30                 out: Connection to 127.0.0.1 closed.
19:42:30         Command returned '1' (failure).

🤔

@cgwalters
Copy link
Collaborator

This needs a rebase

travier and others added 10 commits September 29, 2025 14:50
Update bootc examples to use the new unified bootc command interface:
- Replace cfsctl binary with bootc and use 'bootc internals cfs' subcommands
- Rename composefs-setup-root to bootc-initramfs-setup
- Update dracut module from 37composefs to 37bootc
- Remove sudo requirement from podman build commands
- Update service and module configuration files accordingly

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Signed-off-by: John Eckersberg <[email protected]>
Add test-26-examples-build to validate that the bootc-bls and bootc-uki
example build scripts work correctly.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Signed-off-by: John Eckersberg <[email protected]>
Doing this as a distinct commit so as to not conflate future
modifications with the bulk code movement.

Signed-off-by: John Eckersberg <[email protected]>
As we progress the composefs work along this is becoming more of a
general requirement.  I think it still makes sense to leave it as
optional for now, but I think for the bulk of the cases we'll want to
go ahead and build the initramfs support in.

Signed-off-by: John Eckersberg <[email protected]>
By default bootc will enable fsverity when ext4 is the chosen
filesystem, and we need fsverity to do composefs testing.

Signed-off-by: John Eckersberg <[email protected]>
Since we're running this under tmt, the "system" bootc binaries were
built from source and injected into the integration disk image.  No
need to rebuild these inside of the test job itself.

Signed-off-by: John Eckersberg <[email protected]>
The systemd unit is conditional on this so without it the test will
always fail.

Signed-off-by: John Eckersberg <[email protected]>
@cgwalters
Copy link
Collaborator

We had a live chat about this. So this gives us test coverage of the build+install, but not run. We should land this, but then an important next step will be teasing things out so that basically add composefs-backend as an option to the existing matrix (at least getting through test-readonly and ideally test-20-local-upgrade).

I think as part of that we'll want at least env FEATURES=composefs just build (or maybe we make it "sticky" with touch target/composefs) or so?

Then the GHA matrix expands.

@cgwalters cgwalters enabled auto-merge (rebase) September 29, 2025 20:49
@cgwalters cgwalters merged commit 8cf0971 into bootc-dev:main Sep 29, 2025
27 checks passed
# testcloud barfs on .raw
if test -n "${bcvk}"; then
bcvk to-disk --format=qcow2 --disk-size "${SIZE}" localhost/bootc-integration "${DISK}"
bcvk to-disk --format=qcow2 --disk-size "${SIZE}" --filesystem ext4 localhost/bootc-integration "${DISK}"
Copy link
Collaborator

Choose a reason for hiding this comment

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

OK for now but I think the composefs base image build should override the filesystem type here?

Or hmmm...actually we should fail at bootc container lint time if the base image specifies a filesystem which is known not to support fsverity probably and it's a sealed image.

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.

3 participants