hashicorp / terraform-provider-aws

The AWS Provider enables Terraform to manage AWS resources.
https://registry.terraform.io/providers/hashicorp/aws
Mozilla Public License 2.0
9.85k stars 9.19k forks source link

[New]: data source plural of sns topic: aws_sns_topics #39668

Open nitrocode opened 1 month ago

nitrocode commented 1 month ago

Description

Similar to aws_iam_roles which is a plural of aws_iam_role, it would be nice to have the plural of aws_sns_topic as aws_sns_topics so I can take advantage of the name_regex field

The root issue is that SNS topics generated from cloudformation stacks have randomized suffixes and it would be nice to grab these automatically using a data source in terraform when the SNS topic needs to be reused.

Requested Resource(s) and/or Data Source(s)

Potential Terraform Configuration

data "aws_sns_topics" "example" {
  name_regex = "an_example_topic.*"
}

References

Would you like to implement a fix?

None

github-actions[bot] commented 1 month ago

Community Note

Voting for Prioritization

Volunteering to Work on This Issue