Quoting Benjamin Drung (2022-01-24 17:14:18)
> > to make sure I understand your problem correctly: The mmdebstrap version in
> > unstable is doing exactly what you want/expect but only the version in
> > stable is not doing what you want?
> 
> Yes,

The difference you see between running the stable version with and without
--simulate is that when you use --simulate, there is no apt inside the chroot
and thus apt from the outside is used and that apt has access to different
paths than the apt inside the chroot.

This is not the case anymore with mmdebstrap in unstable because there we never
use apt inside the chroot since apt included this fix:

https://salsa.debian.org/apt-team/apt/-/commit/544d81a26f8c97a2a45262aecbaef4a5b43fb325

That's also one of the reasons why mmdebstrap cannot be backported.

> but the mmdebstrap version in unstable requires one to specify the full path
> to the preference file.
> 
> It would be nice if I could set `Dir::Etc::preferencesparts` to
> something like "$CURDIR/preferences.d/" without needed to parse this
> expression with Bash (since that would not work when specifying it in a YAML
> file for bdebstrap).

I do not yet understand why your "copy-in" essential hook where you copy
bookworm.pref into /etc/apt/preferences.d inside the chroot doesn't solve this
problem for you. Even though mmdebstrap doesn't run apt from inside the chroot
anymore, it uses the configuration from /etc/apt inside the chroot.

Is that not working in your case somehow?

Thanks!

cheers, josch

Attachment: signature.asc
Description: signature

Reply via email to