Skip to content

Commit

Permalink
unify on language of image index
Browse files Browse the repository at this point in the history
Signed-off-by: arewm <[email protected]>
  • Loading branch information
arewm committed Aug 16, 2024
1 parent 32a92bf commit 029db70
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion task/inspect-image/0.1/inspect-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ spec:
skopeo inspect --no-tags --raw docker://"${IMAGE_URL}" > $RAW_IMAGE_INSPECT || status=$?
if [ "$status" -eq 0 ] && [ "$(jq 'has("manifests")' ${RAW_IMAGE_INSPECT})" = "true" ]; then
echo "Found an index image, lookup for amd64 manifest"
echo "Found an image index, lookup for amd64 manifest"
INDEX_IMAGE_MANIFESTS=$(jq ' .manifests | map ( {(.platform.architecture|tostring|ascii_downcase): .digest} ) | add' "${RAW_IMAGE_INSPECT}" || true)
AMD64_MANIFEST_DIGEST=$(jq -r '.amd64' <<< "${INDEX_IMAGE_MANIFESTS}" || true )
Expand Down
2 changes: 1 addition & 1 deletion task/source-build-oci-ta/0.1/source-build-oci-ta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ spec:
raw_inspect=$(skopeo inspect --raw "docker://$BINARY_IMAGE")
if manifest_digest=$(jq -e -r '.manifests[0].digest' <<<"$raw_inspect"); then
# The BINARY_IMAGE is an index image, each manifest in the list has its own SBOM.
# The BINARY_IMAGE is an image index, each manifest in the list has its own SBOM.
# We're gonna assume the base images are the same or similar enough in all the SBOMs.
echo "BINARY_IMAGE ($BINARY_IMAGE) is a manifest list, picking an arbitrary image from the list"
image_without_digest=${BINARY_IMAGE%@*}
Expand Down
2 changes: 1 addition & 1 deletion task/source-build/0.1/source-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ spec:
raw_inspect=$(skopeo inspect --raw "docker://$BINARY_IMAGE")
if manifest_digest=$(jq -e -r '.manifests[0].digest' <<< "$raw_inspect"); then
# The BINARY_IMAGE is an index image, each manifest in the list has its own SBOM.
# The BINARY_IMAGE is an image index, each manifest in the list has its own SBOM.
# We're gonna assume the base images are the same or similar enough in all the SBOMs.
echo "BINARY_IMAGE ($BINARY_IMAGE) is a manifest list, picking an arbitrary image from the list"
image_without_digest=${BINARY_IMAGE%@*}
Expand Down

0 comments on commit 029db70

Please sign in to comment.