[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#742671: marked as done (seeding base-installer/debootstrap_script with an absolute path emits a warning, and just a codename results in an error)



Your message dated Sun, 13 Nov 2016 12:18:35 +0000
with message-id <E1c5tk3-0009ah-Li@fasolo.debian.org>
and subject line Bug#742671: fixed in base-installer 1.166
has caused the Debian Bug report #742671,
regarding seeding base-installer/debootstrap_script with an absolute path emits a warning, and just a codename results in an error
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
742671: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=742671
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: base-installer
Version: 1.145

While reading through the code to figure out the format of the values
expected for "base-installer/debootstrap_script", I noticed that the
code in base-installer prepends "/usr/share/debootstrap/scripts" when it
checks this value, so I assumed the expected format must be something
like "sid".  When something like "sid" is sent, base-installer doesn't
complain, but debootstrap fatal errors because it can't find the script.
When something like "/usr/share/debootstrap/scripts/sid" is given,
base-installer throws a warning (which I can't figure out why it's a
warning and not an error, since the code uses the "error" helper), but
debootstrap is happy and the install continues successfully.

I've attached a patch that makes either of these values work as expected
by prepending "/usr/share/debootstrap/scripts" if the given value exists
within that directory, and only throwing a warning if the value given
either isn't an absolute path that exists or isn't inside the
debootstrap scripts directory.

My proposed d/changelog update is as follows:

  [ Tianon Gravi ]
  * Fix warning given for absolute path "debootstrap_script" values.
  * Update "debootstrap_script" logic to allow bareword script names
    like "sid" as well as absolute paths.

Of course, I'm open to tweaking any aspect of this, especially to better
fit the expected contribution style or scripting preferences. :)

♥,
- Tianon
diff --git a/debian/bootstrap-base.postinst b/debian/bootstrap-base.postinst
index ed2e0ab..7e12a5f 100755
--- a/debian/bootstrap-base.postinst
+++ b/debian/bootstrap-base.postinst
@@ -23,7 +23,9 @@ EXCLUDES="$(printf '%s' "$RET" | sed 's/ /,/g')" || true
 # Check if a specific script should be used
 db_get base-installer/debootstrap_script
 DEBOOTSTRAP_SCRIPT="$RET"
-if [ ! -e /usr/share/debootstrap/scripts/"$DEBOOTSTRAP_SCRIPT" ]; then
+if [ -e /usr/share/debootstrap/scripts/"$DEBOOTSTRAP_SCRIPT" ]; then
+	DEBOOTSTRAP_SCRIPT=/usr/share/debootstrap/scripts/"$DEBOOTSTRAP_SCRIPT"
+elif [ ! -e "$DEBOOTSTRAP_SCRIPT" ]; then
 	error "debootstrap script '$DEBOOTSTRAP_SCRIPT' doesn't exist"
 fi
 

--- End Message ---
--- Begin Message ---
Source: base-installer
Source-Version: 1.166

We believe that the bug you reported is fixed in the latest version of
base-installer, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 742671@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Christian Perrier <bubulle@debian.org> (supplier of updated base-installer package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sun, 13 Nov 2016 07:43:58 +0100
Source: base-installer
Binary: base-installer bootstrap-base
Architecture: source all i386
Version: 1.166
Distribution: unstable
Urgency: medium
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Changed-By: Christian Perrier <bubulle@debian.org>
Description:
 base-installer - base system installation framework (udeb)
 bootstrap-base - Install the base system (udeb)
Closes: 742671
Changes:
 base-installer (1.166) unstable; urgency=medium
 .
   [ Tianon Gravi ]
   * Fix warning given for absolute path "debootstrap_script" values.
   * Update "debootstrap_script" logic to allow bareword script names
     like "sid" as well as absolute paths. (Closes: #742671)
Checksums-Sha1:
 03a3944f800e5ba12dba68363e391b48645625f6 1899 base-installer_1.166.dsc
 e9f7e9f1d9df3e066384d0c1d1ac8889f0038a8f 253592 base-installer_1.166.tar.xz
 cb4e571e15ef47848469d460aaa96ff010f82ae3 4959 base-installer_1.166_20161113T065512z-223c1edd.buildinfo
 2894e700826275da05682dc454ba72a519ef765b 47546 base-installer_1.166_all.udeb
 c1861dd875177f5d0baff637455fe47e215e781f 195862 bootstrap-base_1.166_i386.udeb
Checksums-Sha256:
 0d4002337278cf3f873cb0599843a8f31a0ebdba4cd1970b99f47d35f41342a1 1899 base-installer_1.166.dsc
 98fa134bdc51a492268a7978ef8402371b1f8248d58afc82a1a7b9b2d7b75533 253592 base-installer_1.166.tar.xz
 dc285ff6e032333b544e29c779bb61893ca2318d971491c32d6c9fb44d9adb7b 4959 base-installer_1.166_20161113T065512z-223c1edd.buildinfo
 d80b34536cf667d035b8aab78da5511df7fe96ccd6b5397db9541592cd68aa93 47546 base-installer_1.166_all.udeb
 01322a69bc5e5af521eff276152dffff95c3a6f5c40be8ae879193503d094455 195862 bootstrap-base_1.166_i386.udeb
Files:
 a9cd91f40868e0a680b540ef25495eab 1899 debian-installer required base-installer_1.166.dsc
 3b48727a5a04e604fa0f1ca3491b50aa 253592 debian-installer required base-installer_1.166.tar.xz
 223c1eddd67253dc361e5b11f9c51921 4959 debian-installer required base-installer_1.166_20161113T065512z-223c1edd.buildinfo
 e46b924ccef89b14f34d673e78033d66 47546 debian-installer required base-installer_1.166_all.udeb
 bd69300c7d126535bcb0c09becaa0399 195862 debian-installer required bootstrap-base_1.166_i386.udeb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJYKFc2AAoJEIcvcCxNbiWonfcP/2tjggRQpKZ2EmJ7T7b9yknn
MjaNGfdiD0P9wLbdsZPjEbEycytxuHt5ILG8Mt4Ev4ZIZgpxz60gX2MnWsw0xpWf
UPjjVTM5ViilYOe9ccijzbbuZjer0nnd6WT9OtgITEnckbYjsTTHGTHlUBrAALQ4
qw0a89Hwa89HTE/GUhw/17VAmIYNuoHpb7C7aPQ2xjfNXsldHsUaFXrQ4obASWfQ
MBLm7wl+FmfMNIvgVKj0+RwvZOvvn70v2EQmwZ2enjUBQ8JWsjzoK2hVlE+ybf/T
xMYjSFWtZFb8xUqQW83eLQaAlhyC5E7m07Ac3mei9tINArNFnXAXk9URTRB72vWD
muzCHubzhX2GSxC3vIeV6nGifoRvUkf2rg8hd99qRvXODnUWyL+8GH4wD3wSCqsH
aqheQ3yGx0jNSa/yxAGfSYfoyN3qKFpJv2192HWjpgo8vhMFGis14WDcqaheSWq3
Mxyyo4WUGxgqD9fYGuZonXA13Psu1JYTzqEwiEf+tRpQVZbsYER3qcpE5bohGP+i
XoZbNiBqEsiSRLVr4B31VjbPLbmm5Hmij4UvD16Qsk2UXkgo55HiZLDapKk9DyZP
inoTSAlCxvg2mo4Ywx4oRrULgzlMfWtfr15Rdl+LuAHgP4BB3yvtwYdy4eU9SK20
TFOOTKfb8Wxqv4qGlajo
=BYFf
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: