From: Mark Wooding Date: Sun, 29 Sep 2019 13:00:49 +0000 (+0100) Subject: bin/chroot-maint: Prevent debconf from messing things up. X-Git-Url: https://git.distorted.org.uk/~mdw/distorted-chroot/commitdiff_plain/a6395bc305a7932895bcb591e15b65010ac2b3d5 bin/chroot-maint: Prevent debconf from messing things up. --- diff --git a/bin/chroot-maint b/bin/chroot-maint index a24d173..2f91e9c 100755 --- a/bin/chroot-maint +++ b/bin/chroot-maint @@ -1477,6 +1477,12 @@ with toplevel_handler(): C = Config() CREATE = Tag("CREATE") FORCE = Tag("FORCE") +DEBCONF_TWEAKS = """ + DEBIAN_FRONTEND=noninteractive; export DEBIAN_FRONTEND + DEBIAN_PRIORITY=critical export DEBIAN_PRIORITY + DEBCONF_NONINTERACTIVE_SEEN=true; export DEBCONF_NONINTERACTIVE_SEEN +""" + def check_fresh(fresh, update): """ Compare a refresh mode FRESH against an UPDATE time. @@ -2222,7 +2228,8 @@ class ChrootJob (BaseJob): ## Finishing touches. progress("finishing touches") - run_schroot_source(dist, arch, ["eatmydata", "sh", "-e", "-c", """ + run_schroot_source(dist, arch, ["eatmydata", "sh", "-e", "-c", + DEBCONF_TWEAKS + """ apt-get update apt-get -y upgrade apt-get -y install "$@" @@ -2240,7 +2247,8 @@ class ChrootJob (BaseJob): with Cleanup() as clean: dist, arch = me._dist, me._arch clean.enter(lockfile(chroot_src_lockfile(dist, arch))) - run_schroot_source(dist, arch, ["eatmydata", "sh", "-e", "-c", """ + run_schroot_source(dist, arch, ["eatmydata", "sh", "-e", "-c", + DEBCONF_TWEAKS + """ apt-get update apt-get -y dist-upgrade apt-get -y autoremove @@ -2311,7 +2319,8 @@ class CrossToolsJob (BaseJob): ## Make sure the donor tree is up-to-date, and install the extra ## packages we need. progress("install tools packages") - run_schroot_session(session, ["eatmydata", "sh", "-e", "-c", """ + run_schroot_session(session, ["eatmydata", "sh", "-e", "-c", + DEBCONF_TWEAKS + """ apt-get update apt-get -y upgrade apt-get -y install "$@"