Bug#922019: cdimage.debian.org: Non-free live builds missing contrib and non-free components
Package: cdimage.debian.org
Severity: normal
Tags: patch
Debian Images Team,
Unofficial non-free live builds for both stretch and buster
are missing the contrib and non-free components in base.list.
# Stretch live
$ cat /etc/apt/sources.list.d/base.list
deb http://deb.debian.org/debian/ stretch main
#deb-src http://deb.debian.org/debian/ stretch main
# Buster live
$ cat /etc/apt/sources.list.d/base.list
deb http://deb.debian.org/debian/ buster main
#deb-src http://deb.debian.org/debian/ buster main
The root cause is in vmdebootstrap.
filesystem.py configure_apt() has the following lines:
248 line = 'deb %s %s main\n' % (mirror, self.settings['distribution'])
250 line = '#deb-src %s %s main\n' % (mirror, self.settings['distribution'])
That file could be patched with something like this beforehand:
components = 'main'
if 'nonfree' in rootdir:
components += ' contrib non-free'
...
However, since vmdebootstrap is deprecated, I think it should be left alone.
Attached is an **untested** workaround patch for live-setup
available/live-customise.sh.
Thank you!
Daniel Lewart
--- a/available/live-customise.sh 2019-02-07 06:52:14.000000000 -0600
+++ b/available/live-customise.sh 2019-02-11 00:00:00.000000000 -0600
@@ -70,3 +70,10 @@
mv ${rootdir}/etc/resolv.conf ${rootdir}/etc/resolv.conf.bak
+# Workaround for vmdebootstrap filesystem.py configure_apt() components bug
+case ${rootdir} in
+ *nonfree*)
+ sed -i 's/ main$/ main contrib non-free/' ${rootdir}/etc/apt/sources.list.d/base.list
+ chroot ${rootdir} apt-get -qq update
+ ;;
+esac
Reply to: