-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
Allow exempting selected elements of map attribute in lifecycle ignore_changes #29596
Comments
Hi @rafabu! Thanks for sharing this use-case. At the moment we're not planning any modifications to the However, this is still a valid use-case and so we can use this issue to represent the use-case even though the final design to meet that use-case, once we get there, will probably be something separate from In the meantime though, I think having a subset of AWS tags be managed separately from Terraform is a common enough use-case that the AWS provider already has a specialized solution for it. The Resource Tagging guide describes how you can configure the provider to ignore certain tag names and some other similar possibilities. Those features belong to the AWS provider rather than to Terraform Core, so if you have feedback about them it'd be best to send it to the AWS provider repository. |
I will have a look at the aws guide - however; we are working mostly with azurerm resources. So we will have to wait until the redesigned, versatile |
You could also send the Azure provider team feedback about your use-case. Specialized features addressing one concrete problem are almost always easier and faster to design than general solutions, and the experience with specialized solutions often informs the general ones, so I'd always suggest pursuing the more specialized answer first if the lack of a particular feature is causing you significant problems. |
Current Terraform Version
Use-cases
Every now and again there is a need to assure, terraform only manages a subset of values in an attribute of type map. Specifically with resource tags:
While most tags of a cloud resource may be changed by downstream processes throughout the entire lifecycle of a resource, a few selected ones must remain under control of the IaC workflows.
Proposal
Currently we can ignore specific tags by listing their keys
but we would need something like
in order to ignore all but selected keys.
References
Similar requests - also with wildcards and/or on complex attributes:
The text was updated successfully, but these errors were encountered: