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.78k stars 9.14k forks source link

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

Open nitrocode opened 5 days ago

nitrocode commented 5 days 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 5 days ago

Community Note

Voting for Prioritization

Volunteering to Work on This Issue