From: Plom Heller Date: Mon, 7 Sep 2026 03:11:08 +0000 (+0200) Subject: Disable automatic installation of APT recommends. X-Git-Url: https://plomlompom.com/repos/%7B%7Bdb.prefix%7D%7D/task?a=commitdiff_plain;h=a4497988536a45d0e21ce481614820d7f2bdc14b;p=confplom Disable automatic installation of APT recommends. --- diff --git a/setup_scripts/install_debian.sh b/setup_scripts/install_debian.sh index a8a3330..5ef5ed9 100755 --- a/setup_scripts/install_debian.sh +++ b/setup_scripts/install_debian.sh @@ -5,6 +5,7 @@ FNAME_INITRD=initrd.img FNAME_NM_CONN=wifi.nmconnection FNAME_VMLINUZ=vmlinuz +PATH_APT_NORECOMMENDS=/etc/apt/apt.conf.d/90-no-recommends PATH_CRYPTTAB=/etc/crypttab PATH_EFI=/boot/efi PATH_FSTAB=/etc/fstab @@ -24,6 +25,7 @@ NAME_ROOT="${NAME_BOOT}" # constants derived from changeables PATH_EFI_NAME_BOOT="${PATH_EFI}/${NAME_BOOT}" +PATH_MNT_APT_NORECOMMENDS="${PATH_MNT_ROOT}${PATH_APT_NORECOMMENDS}" PATH_MNT_APT_SOURCES="${PATH_MNT_ROOT}/etc/apt/sources.list" PATH_MNT_CRYPTTAB="${PATH_MNT_ROOT}${PATH_CRYPTTAB}" PATH_MNT_FSTAB="${PATH_MNT_ROOT}${PATH_FSTAB}" @@ -86,6 +88,10 @@ printf '%s UUID=%s none luks\n' \ msg 'Enabling non-free-firmware component in target sources.list …' sed -i 's/ main$/ main non-free-firmware/' "${PATH_MNT_APT_SOURCES}" +# reduce installation footprint +msg 'Disabling automatic installation of APT recommends …' +printf 'APT::Install-Recommends "false";\n' >| "${PATH_MNT_APT_NORECOMMENDS}" + # set up kernel, initrd etc. msg 'Into chroot environment installing LVM tools, kernel, initrd etc. …' chroot_sh "apt-get -qq update"