-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Unwanted deletion of aws_security_group_rule on second apply/plan #12356
Comments
Might very well be linked/duplicate of #11059 |
I think this is expected behaviour given the comments at the top of https://www.terraform.io/docs/providers/aws/r/security_group.html - you mix an SG with in-line rules (https://github.com/obourdon/terraform-bug-12356/blob/master/0.12/lb.tf#L14-L50) with an SG rule (https://github.com/obourdon/terraform-bug-12356/blob/master/0.12/netdata.tf#L41-L51). You need to either put all rules as in-line, or all rules as separate |
@mattburgess thanks for this explanation. Indeed this makes a lot of sense and I should read documentation more carefully. |
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. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Terraform Version
0.11(.14) and 0.12(.23)
Terraform provider version
2.52.0
Affected Resource(s)
Terraform Configuration Files
See this repository for easy reproduction
Expected Behavior
Has nothing changed, plan should say so in its output
Actual Behavior
Removal of aws_security_group_rule
Steps to Reproduce
see README.md in repository mentioned above
The text was updated successfully, but these errors were encountered: