Skip to content

[New Function]: tag_to_terraform_types and terraform_to_tag_type #45397

@jar-b

Description

@jar-b

What new functionality are you requesting?

  • tag_to_terraform_types
  • terraform_to_tag_type

Description

These provider defined functions would expose mappings between the tag resource types used when authoring organizational tag policies, and resource types in the Terraform AWS provider. As one tag type can map to multiple Terraform types, the "tag to Terraform" result is an array and the "Terraform to tag" result will be a string.

Potential Terraform Configuration

# returns: ["aws_cloudwatch_log_group"]
output "example" {
  value = provider::aws::tag_to_terraform_types("logs:log-group")
}
# returns: "logs:log-group"
output "example" {
  value = provider::aws::terraform_to_tag_type("aws_cloudwatch_log_group")
}

References

Relates #45143
Depends on #45213

Would you like to implement the enhancement?

No

Metadata

Metadata

Assignees

No one assigned

    Labels

    functionPertains to provider functions.new-functionIntroduces a new function.tagsPertains to resource tagging.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions