qemu-commits
[Top][All Lists]
Advanced

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

[Qemu-commits] [qemu/qemu] c1958e: docker: Improved image checksum


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] c1958e: docker: Improved image checksum
Date: Tue, 14 Nov 2017 00:38:40 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: c1958e9d54c8de85ceda7c96b302b75a2f67b4e1
      
https://github.com/qemu/qemu/commit/c1958e9d54c8de85ceda7c96b302b75a2f67b4e1
  Author: Fam Zheng <address@hidden>
  Date:   2017-11-08 (Wed, 08 Nov 2017)

  Changed paths:
    M tests/docker/docker.py

  Log Message:
  -----------
  docker: Improved image checksum

When a base image locally defined by QEMU, such as in the debian images,
is updated, the dockerfile checksum mechanism in docker.py still skips
updating the derived image, because it only looks at the literal content
of the dockerfile, without considering changes to the base image.

For example we have a recent fix e58c1f9b35e81 that fixed
debian-win64-cross by updating its base image, debian8-mxe, but due to
above "feature" of docker.py the image in question is automatically NOT
rebuilt unless you add NOCACHE=1. It is noticed on Shippable:

https://app.shippable.com/github/qemu/qemu/runs/541/2/console

because after the fix is merged, the error still occurs, and the log
shows the container image is, as explained above, not updated.

This is because at the time docker.py was written, there wasn't any
dependencies between QEMU's docker images.

Now improve this to preprocess any "FROM qemu:*" directives in the
dockerfiles while doing checksum, and inline the base image's dockerfile
content, recursively. This ensures any changes on the depended _QEMU_
images are taken into account.

This means for external images that we expect to retrieve from docker
registries, we still do it as before. It is not perfect, because
registry images can get updated too. Technically we could substitute the
image name with its hex ID as obtained with $(docker images $IMAGE
--format="{{.Id}}"), but --format is not supported by RHEL 7, so leave
it for now.

Reported-by: Philippe Mathieu-Daudé <address@hidden>
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Tested-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
Signed-off-by: Fam Zheng <address@hidden>


  Commit: 6423795efc5b665c595d9a0bf93cfbbca00362e9
      
https://github.com/qemu/qemu/commit/6423795efc5b665c595d9a0bf93cfbbca00362e9
  Author: Philippe Mathieu-Daudé <address@hidden>
  Date:   2017-11-08 (Wed, 08 Nov 2017)

  Changed paths:
    M tests/docker/Makefile.include

  Log Message:
  -----------
  docker: correctly escape $BACKEND in the help output

In Makefiles the $ must be escaped as $$ in shell uses.

Since 8a2390a4f47:

 $ make docker
     [...]
     NETWORK=1            Enable virtual network interface with default backend.
     NETWORK=ACKEND     Enable virtual network interface with ACKEND.

Once escaped:

 $ make docker
     [...]
     NETWORK=1            Enable virtual network interface with default backend.
     NETWORK=$BACKEND     Enable virtual network interface with $BACKEND.

Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Fam Zheng <address@hidden>


  Commit: 02e5844db2e4fb074f685a709abf82d2b8d2bed8
      
https://github.com/qemu/qemu/commit/02e5844db2e4fb074f685a709abf82d2b8d2bed8
  Author: Peter Maydell <address@hidden>
  Date:   2017-11-13 (Mon, 13 Nov 2017)

  Changed paths:
    M tests/docker/Makefile.include
    M tests/docker/docker.py

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/famz/tags/docker-pull-request' into 
staging

# gpg: Signature made Fri 10 Nov 2017 13:41:01 GMT
# gpg:                using RSA key 0xCA35624C6A9171C6
# gpg: Good signature from "Fam Zheng <address@hidden>"
# Primary key fingerprint: 5003 7CB7 9706 0F76 F021  AD56 CA35 624C 6A91 71C6

* remotes/famz/tags/docker-pull-request:
  docker: correctly escape $BACKEND in the help output
  docker: Improved image checksum

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/4e8a737c092d...02e5844db2e4

reply via email to

[Prev in Thread] Current Thread [Next in Thread]