Fix bug in Docker image build process which caused tags to have improper manifests in DockerHub #2648
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
References
Description
Fix bug in Docker build process, where the manifests for the
latest
andlatest-dist
images on DockerHub were invalid.The core issues was that in #2644, both the
latest
andlatest-dist
build processes were sharing the same artifact to store their digests. When the manifest was built for one of those tags, it was including every digest that had been built so far.This behavior resulted in the
latest
tag in DockerHub having a manifest that included all the following:latest
image version for AMD64latest-dist
image version for AMD64latest
image version for ARM64It also meant that the
latest-dist
tag ONLY included the longest running image:latest-dist
image for ARM64The reason for this was a race condition where the ARM64 image took longer to build. At the point where the
latest
ARM64 image completed, both of the AMD64 images were already completed. Since they shared the same artifact, both AMD64 images WRONGLY ended up included in the same manifest.This PR also does some minor cleanup in this
docker.yml
including:matrix
parameters to list thearch
first, so that step/jobs names in GitHub are clearer.dspace-angular (false, linux/amd64, ubuntu-latest)
dspace-angular (linux/amd64, ubuntu-latest, false)
Instructions for Reviewers