-
Notifications
You must be signed in to change notification settings - Fork 12
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
Push fails when image already exists on repository with tag and is immutable #750
Comments
Here's an issue from the docker repo: |
Thanks for reaching out. Are you using any ECR CLI commands or can you provide more details on your workflow? It seems like this issue relates more to Docker/ECR than the CLI directly. We can forward issues to service teams like ECR if necessary. I saw one other issue (aws/containers-roadmap#862) in an AWS repository referencing that error but it looks like that was closed a few years ago. |
We do a build with the SHA of the git commit and tag that for each PR and then when it's merged to branch associated with an environment we get the manifest using this command:
And then we tag it to that branch using this command:
That works just fine, but if the deploy fails and we need to re-run that, then the |
aws ecr batch-get-image --repository-name mycompany/myrepo --image-ids imageTag="${git_sha} --query 'images[].imageManifest' --output text |
So this will be fixed in an upcoming version? If so, which version number and is there an expected release date? |
Thanks for following up. I'm going to reach out to the ECR team regarding this issue (ref: P130774841), as they own the underlying BatchGetImage / PutImage APIs. I'm also going to transfer this to our cross-SDK repository since service APIs like these are used across AWS SDKs in addition to the AWS CLI. I'll share any updates here in the issue. |
We heard back from the ECR team and they recommended creating an issue in this repository where they publicly tracks customer feature requests: https://github.com/aws/containers-roadmap You can can see if a similar feature request already exists, or create one if not. Those issues are reviewed by the ECR service team. As far as workarounds on the client-side, you can either treating |
This issue is now closed. Comments on closed issues are hard for our team to see. |
Describe the bug
Pushing an image to a tag where it already exists reports an error
Expected Behavior
If the image is identical, then it should report that it already exists without an error
Current Behavior
An error is reported with return code
254
Reproduction Steps
Possible Solution
Report that it already exists and return success
Additional Information/Context
No response
CLI version used
aws-cli/2.15.17 Python/3.11.7 Darwin/23.4.0 source/x86_64 prompt/off
Environment details (OS name and version, etc.)
macOS 14.4.1
The text was updated successfully, but these errors were encountered: