Branch: refs/heads/master
Home:
https://github.com/tribe29/checkmk
Commit: c0869f7050e12208228548a472ce187df36f7e05
https://github.com/tribe29/checkmk/commit/c0869f7050e12208228548a472ce187df…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2021-10-15 (Fri, 15 Oct 2021)
Changed paths:
M tests/scripts/install-cmk.py
M tests/testlib/containers.py
Log Message:
-----------
Automatically update build images with new Checkmk packages
When building the daily test containers from the build base images, the
Checkmk packages are downloaded by a script (install-cmk.py) in the
context of a container. Changes to these packages were previously not
detected by the build mechanism and the image had to be invalidated
manually for the jobs to build a new image with a newer package.
This commit solves this problem now:
* During installation the hash of the Checkmk package is saved in the
image filesystem.
* After installation the hash is read from the filesystem and written
to the image label "org.tribe29.cmk_hash".
* Subsequent builds compare the hash to the HASHES file of the Checkmk
version on our download server.
* Once a mismatch is detect, the image is being rebuilt.
Maybe we should transform this to a more docker like approach using
Dockerfile and so on which would use the caching capabilities of docker.
This might simplify our logic. But I am not entirely sure that this
would fit our requirements. Keeping the current approach for the moment.
CMK-8638
Change-Id: I8a2c8b2961893d9e989a32d34eb2d03ed47840d0