diff --git a/os/build.py b/os/build.py index 8bae320..c84070d 100755 --- a/os/build.py +++ b/os/build.py @@ -165,6 +165,9 @@ def main(): # so we need to copy them somewhere else and restore them after the install. for listpath in pathlib.Path('config/archives').glob('*.list.chroot'): run(["cp", str(listpath), f"config/includes.chroot/usr/local/share/target-sources/{listpath.name.removesuffix('.chroot')}"]) + # Insert distribution into source configs. + for sourcepath in pathlib.Path('config/includes.chroot/usr/local/share/target-sources').glob('*'): + edit_file(sourcepath, lambda s: s.replace("@DISTRIBUTION@", DISTRIBUTION)) elif args.variant == "contestant": # Insert root password into hook script. edit_file("config/hooks/live/2010-contestant.hook.chroot", diff --git a/os/layers/training-installer/includes.chroot/usr/local/share/target-sources/debian.sources b/os/layers/training-installer/includes.chroot/usr/local/share/target-sources/debian.sources index a7c1e88..fd89bcb 100644 --- a/os/layers/training-installer/includes.chroot/usr/local/share/target-sources/debian.sources +++ b/os/layers/training-installer/includes.chroot/usr/local/share/target-sources/debian.sources @@ -1,11 +1,11 @@ Types: deb deb-src URIs: http://deb.debian.org/debian -Suites: bookworm bookworm-updates +Suites: @DISTRIBUTION@ @DISTRIBUTION@-updates Components: main contrib non-free non-free-firmware Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg Types: deb deb-src URIs: http://deb.debian.org/debian-security -Suites: bookworm-security +Suites: @DISTRIBUTION@-security Components: main contrib non-free non-free-firmware Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg