1

I have created main.tf which has the code for following resources and are created using for_each with variables.tf having the map for subnets

1 vpc

2 public subnets

2 private subnets

With in the same main.tf,I want to dynamically associate the route table to the created subnets but unable to understand how to reference the subnet ids using output or any other process.

Poro
  • 11
  • 3
  • This answered my query. Thanks https://stackoverflow.com/questions/63385511/attach-multiple-private-subnet-to-route-table-for-each-terraform?rq=1 – Poro Aug 25 '22 at 10:40

0 Answers0