-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
aws_ecr_repository_policy tries to enforce order of principals when AWS insists on a different random ordering. #19365
Comments
Maybe it is the same issue like #17024 ? |
Right. It's at least the same at the surface level.
There are places where this persists (aws_ecr_repository_policy is a place
where it's a pain point for us), and places where it's resolved
(aws_iam_policy iirc).
I think the general tact to take to solve this would be to sort both what
AWS says is there and what Terraform wants to apply, and then do the
comparison.
Or find the code that deals with aws_iam_policy, and adjust to match that.
[image: Ben Longman]
Ben Longman
Senior DevOps Engineer
(925) 548-3649 <+19255483649>
[image: Snapdocs] <http://www.snapdocs.com/>
------------------------------
*The information transmitted by this email is intended only for the person
or entity to which it is addressed. This email may contain proprietary,
business-confidential and/or privileged material. If you are not the
intended recipient of this message, be aware that any use, review,
retransmission, distribution, reproduction or any action taken in reliance
upon this message is strictly prohibited. If you received this in error,
please contact the sender and delete the material from all computers.*
…On Thu, Aug 5, 2021 at 11:53 PM Thomas Zahari ***@***.***> wrote:
Maybe it is the same issue like #17024
<#17024> ?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#19365 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ANHE76IWMAZTM7C363R4ZADT3OBFNANCNFSM4425UQJA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
|
Potentially related: jen20/awspolicyequivalence#10. |
This functionality has been released in v3.69.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Community Note
Terraform CLI and Terraform AWS Provider Version
Terraform v0.14.6
hashicorp/aws v3.39.0 (self-signed, key ID 34365D9472D7468F)
Affected Resource(s)
aws_ecr_repository_policy.policy ( multiple in a for_each )
Terraform Configuration Files
Please include all Terraform configurations required to reproduce the bug. Bug reports without a functional reproduction may be closed without investigation.
Expected Behavior
We should see no changes.
Actual Behavior
Tries to shuffle the principals for every resource. Each resource starts with a different ordering of principals, but the endpoint is always the same order. Looks like this.
Steps to Reproduce
Create a ecr repo with a policy that has multiple varied principals.
terraform apply
(will show the changes)terraform apply
(will show the changes again)Important Factoids
Tried removing and reapplying all policies. It didn't help.
References
The text was updated successfully, but these errors were encountered: