Repository navigation
fix(goconserver): the bootstrap scrub removes the cache the next package needs - #103
Merged
dhilst merged 2 commits intoNov 9, 2026
Conversation
…age needs
goconserver reclaims its own build chroot with --scrub=chroot --scrub=bootstrap.
The bootstrap scrub also removes the shared /var/cache/mock/<cfg>-bootstrap
cache, and mock does not put it back. The next package in the run binds that
cache into its own bootstrap and fails before it compiles anything:
/bin/mount -n -o bind /var/cache/mock/alma+epel-10-x86_64-bootstrap/yum_cache
/var/lib/mock/alma+epel-10-x86_64-bootstrap-<uniqueext>/root/var/cache/yum
mock exits 32. conserver-xcat builds immediately after goconserver, so
xcat-dep-build-el10-x86_64 build 143 failed there after five packages had built,
and took the EL family with it. Only the el10 bootstrap is container based and
binds that cache, which is why el8 and el9 finished the same run.
The three cache directories are recreated after the scrub. The scrub itself is
left alone: mock knows the order to unmount this build's bootstrap tree in, and
removing it by hand is what propagates an unmount to the host.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
mockbuild.pl recreates the bootstrap cache that mock --scrub=bootstrap removes, and it built the path from a literal /var/cache/mock. goconserver-openeuler.t runs the builder under unshare --user --map-root-user, which maps root but leaves the host cache unwritable, so the builder died in make_path and 12 of 160 assertions failed with "mkdir /var/cache/mock/<cfg>-bootstrap: Permission denied". The path moved into MockBuildUtils::mock_bootstrap_cache_dirs, which takes the cache root from XCAT_MOCK_CACHE_ROOT and falls back to /var/cache/mock, so the production default does not change. run_case points it at a directory of each case's own, and the builder now writes nothing outside the test's temporary tree. Each of the six configurations asserts all three directories are present after the scrub. Removing the recreate loop from mockbuild.pl fails exactly those six and nothing else, so the assertions measure the fix rather than the fixture. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
goconserver reclaims its own build chroot with
--scrub=chroot --scrub=bootstrap. The bootstrap scrub also removes the shared/var/cache/mock/<cfg>-bootstrapcache, and mock does not put it back. The next package in the run binds that cache into its own bootstrap and fails before it compiles anything:mock exits 32. conserver-xcat builds immediately after goconserver, so the el10 dep build failed there after five packages had built, and the whole EL family failed with it. Only the el10 bootstrap is container based and binds that cache, which is why el8 and el9 finished the same run.
The three cache directories are recreated after the scrub. The scrub itself is unchanged: mock knows the order to unmount this build's bootstrap tree in, and removing it by hand is what propagates an unmount to the host