[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 15/17] docker: ignore distro versioning of debootstra
From: |
Alex Bennée |
Subject: |
[Qemu-devel] [PULL 15/17] docker: ignore distro versioning of debootstrap |
Date: |
Tue, 24 Jul 2018 11:51:07 +0100 |
We do a minimum version check for the debootstrap but if the distro
has added their own minor version tick it would fail and fall-back to
the SCM version. This is sub-optimal as the latest/greatest version
may be broken at any one particular time. We fix that with a little
sed magic on the version string before passing to our ugly shell
versioning check.
Signed-off-by: Alex Bennée <address@hidden>
Tested-by: Philippe Mathieu-Daudé <address@hidden>
diff --git a/tests/docker/dockerfiles/debian-bootstrap.pre
b/tests/docker/dockerfiles/debian-bootstrap.pre
index ea324d6e4a..3b0ef95374 100755
--- a/tests/docker/dockerfiles/debian-bootstrap.pre
+++ b/tests/docker/dockerfiles/debian-bootstrap.pre
@@ -56,10 +56,13 @@ if [ -z $DEBOOTSTRAP_DIR ]; then
if [ -z $DEBOOTSTRAP ]; then
echo "No debootstrap installed, attempting to install from SCM"
NEED_DEBOOTSTRAP=true
- elif ! (echo "${MIN_DEBOOTSTRAP_VERSION}" ; "${DEBOOTSTRAP}" --version \
- | cut -d ' ' -f 2) | sort -t . -n -k 1,1 -k 2,2 -k 3,3 -c
&>/dev/null; then
- echo "debootstrap too old, attempting to install from SCM"
- NEED_DEBOOTSTRAP=true
+ else
+ INSTALLED_VERSION=$(${DEBOOTSTRAP} --version | sed 's/debootstrap
\([0-9\.]*\)[^0-9\.]*.*/\1/')
+ if ! (echo "${MIN_DEBOOTSTRAP_VERSION}" ; echo "${INSTALLED_VERSION}")
\
+ | sort -t . -n -k 1,1 -k 2,2 -k 3,3 -C ; then
+ echo "debootstrap too old, attempting to install from SCM"
+ NEED_DEBOOTSTRAP=true
+ fi
fi
if $NEED_DEBOOTSTRAP; then
DEBOOTSTRAP_SOURCE=https://salsa.debian.org/installer-team/debootstrap.git
--
2.17.1
- [Qemu-devel] [PULL 04/17] docker: fail more gracefully on docker.py check, (continued)
- [Qemu-devel] [PULL 04/17] docker: fail more gracefully on docker.py check, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 05/17] docker: split configure_qemu from build_qemu, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 06/17] docker: move make check into check_qemu helper, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 02/17] docker: base debian-tricore on qemu:debian9, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 07/17] docker: gracefully skip check_qemu, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 11/17] docker: drop QEMU_TARGET check, fallback in EXECUTABLE not set, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 08/17] docker: Makefile.include don't include partial images, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 12/17] docker: report hint when docker.py check fails, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 10/17] docker: add expansion for docker-test-FOO to Makefile.include, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 09/17] docker: add test-unit runner, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 15/17] docker: ignore distro versioning of debootstrap,
Alex Bennée <=
- [Qemu-devel] [PULL 13/17] docker: Update debootstrap script after Debian migration from Alioth to Salsa, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 14/17] docker: add commentary to debian-bootstrap.docker, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 17/17] tests/tcg: remove runcom test, Alex Bennée, 2018/07/24
- [Qemu-devel] [PULL 16/17] docker: perform basic binfmt_misc validation in docker.py, Alex Bennée, 2018/07/24
- Re: [Qemu-devel] [PULL for 3.0 00/17] docker fixes and tcg test tweak, Peter Maydell, 2018/07/24