[Rpm-maint] [rpm-software-management/rpm] Replace fakechroot with proper container technology (PR #2559)
Michal Domonkos
notifications at github.com
Wed Jul 12 23:13:26 UTC 2023
> At that point, adding a legacy backend using fakechroot (or just chroot perhaps) would be a possibility and while I won't make any promises, I _might_ look at that later.
Hmm, I totally forgot that `chroot` alone wouldn't suffice, the system would also need to have something like overlayfs and that's only available on Linux AFAIK.
Overlayfs is used here to create CoW snapshots of the root filesystem, as obviously making an actual copy for each test is too expensive and slow. The old test suite works around this by cherry picking the core files and directories to symlink into the per-test tree and lets fakechroot do its trickery where it resolves those symlinks outside of the jail while making it appear like a regular `chroot`. This kind of trickery is one of the reasons we want to get rid of fakechroot as it's unpredictable and has weird side effects.
So it turns out the new test suite will only support Linux systems for the time being. However, since it's made extensible, one can write a backend for non-Linux systems that uses a CoW technology native to the given platform.
Adding a backend using fakechroot + symlinks (i.e. the old approach) would be possible, too, but I don't think we want to go in that direction since removing fakechroot is the main motivation for this PR (and the associated #1580).
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2559#issuecomment-1633321474
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/pull/2559/c1633321474 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20230712/68e8ca82/attachment-0001.html>
More information about the Rpm-maint
mailing list