fix: add platform argument to preflight calls#12
Merged
Conversation
razvan
reviewed
Apr 23, 2024
Member
razvan
left a comment
There was a problem hiding this comment.
a new version will be needed (for GH actions to pull and so on), maybe also add a line to the changelog
razvan
approved these changes
Apr 24, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Part of stackabletech/issues#559.
The architecture is checked when the arguments are parsed, but preflight ignores the value unless the image points to a manifest list, in which case the correct image is selected.
Only stackable-experimental contains manifest lists at the moment, so these calls will always result in the default (presumably fo the calling environment) being fetched:
check-container -i 24.3.0 -p hive -a linux/amd64--> amd64 imagecheck-container -i 24.3.0 -p hive -a linux/arm64--> amd64 imagepreflight .../stackable/hive:3.1.3-stackable24.3.0 --platform linux/amd64--> amd64 imagepreflight .../stackable/hive:3.1.3-stackable24.3.0 --platform linux/arm64--> amd64 imagePreflight seems to provide the prefix so this is removed before passing the command off to preflight:
preflight .../stackable-experimental/hive:3.1.3-stackable24.3.0 --platform linux/amd64--> no child with platform linux/linux/amd64preflight .../stackable-experimental/hive:3.1.3-stackable24.3.0 --platform linux/arm64--> no child with platform linux/linux/arm64When pointing at a manifest list, the correct images are selected:
preflight .../stackable-experimental/hive:3.1.3-stackable24.3.0 --platform amd64--> amd64 imagepreflight .../stackable-experimental/hive:3.1.3-stackable24.3.0 --platform arm64--> arm64 image