Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ecr scan fail after build on buildx #186

Closed
kimsw61 opened this issue Jan 20, 2023 · 3 comments
Closed

ecr scan fail after build on buildx #186

kimsw61 opened this issue Jan 20, 2023 · 3 comments

Comments

@kimsw61
Copy link

kimsw61 commented Jan 20, 2023

Behaviour

Steps to reproduce this issue

  1. ecr scan fail after arm64 build from buildx

Expected behaviour

I builded through github action with buildx using 2.2.1

but next step (ecr scan) is failed.

error message is on the below.

"An artifact with media type 'application/vnd.oci.image.index.v1+json' cannot be scanned. For more information, see the Amazon ECR documentation."

Actual behaviour

actually, i used on v2 before, after issue, I was changed v2 to v2.2.1

Command

docker buildx build . -f infra/Dockerfile --platform=linux/arm64 -t $ECR_REGISTRY/stg-$ECR_REPOSITORY:$IMAGE_TAG --push

@tonistiigi
Copy link
Member

moby/buildkit#3499

@kimsw61
Copy link
Author

kimsw61 commented Jan 24, 2023

i got answer from aws global communication center under below.

what should i do for fix this error?

In the error information, we have confirmed that there is an artifact of 'Application/vND.OCI.IMAGE.INDEX.V1+JSON' IMAGE Manifest. You can see that ECR does not support multiple architecture image scanes [1].

The first Amazon ECR Scan Repositories deals with the following supported media types: See [2].

  • "Application/vND.DOCKER.DISTRIBUTION.MANIFEST.V1+JSON"

  • "Application/vND.DOCKER.DISTRIBUTION.MANIFEST.V1+Prettyjws"

  • "Application/vN.oci.image.Manifest.v1+json"

  • "Application/vND.DOCKER.DISTRIBUTION.MANIFEST.V2+JSON"

Scratch images and DockERV2LISTMEDYATYPE images are not supported.

The problem [3] was released on a public container roadmap and found that the same function was required. At this time, the ECR team cannot see the roadmap for this feature. This feature is a feature inside the ECR service team, so you can't provide ETA to use it.

[1] - Multi-architecture images - https://developer.arm.com/documentation/102475/0100/Multi-architecture-images
[2] - Supported operating systems and media types - https://docs.aws.amazon.com/inspector/latest/user/enable-disable-scanning-ecr.html#ecr-supported-media
[3] - [ECR] [request]: ECR Image scanning does not support multi-arch images - aws/containers-roadmap#1683

@jedevc
Copy link
Contributor

jedevc commented Jan 25, 2023

Closing in preference of moby/buildkit#3499.

@jedevc jedevc closed this as completed Jan 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants