Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
images: Remove trailing newlines from before computing SHA256
Some versions of buildx may add a newline at the end of the output for "buildx imagetools inspect". That additional newline leads to a different SHA256 hash: $ docker buildx version github.com/docker/buildx v0.3.1-tp-docker 6db68d029599c6710a32aa7adcba8e5a344795a7 $ docker buildx imagetools inspect "quay.io/cilium/cilium-runtime:e5902a650726387b39d080ce77a9ef6ccb89eabc" --raw 2>/dev/null | sha256sum | cut -d " " -f 1 7b0efa641ec89ee9860abfcce9a699765fee0f6f6337d4fe2d5cef09f60eb88c $ docker buildx imagetools inspect "quay.io/cilium/cilium-runtime:e5902a650726387b39d080ce77a9ef6ccb89eabc" --raw 2>/dev/null | perl -0pe 's/\n\Z//' | sha256sum | cut -d " " -f 1 38995ce0cf801983fb3706ed76fa3df03572d4cd7c0d2c4281fe622e7cd77e51 This is turn means the local and CI runs of the update-xxx-image make targets may lead to different image tags. This commit fixes it by removing any trailing newline from the output. Co-authored-by: Quentin Monnet <[email protected]> Signed-off-by: Paul Chaignon <[email protected]>
- Loading branch information