Each resource in Terraform exports data and information about the resource. This data can then be used as input into other resources. When data from one resource is used for another then it becomes a dependency. Thankfully Terraform automatically figures out any dependencies allowing users not to have to worry about it much.
In this video we'll create a few resources using the values of one resource as the input into other resources. Below are a few things that we'll cover.
Create an AWS VPC, Subnet and Instance
Use the exported attributes from one resource into another creating a dependency
Code Examples:
https://github.com/WillBrock/terrafor...
AWS VPC:
https://www.terraform.io/docs/provide...
AWS Subnet:
https://www.terraform.io/docs/provide...
AWS Instance:
https://www.terraform.io/docs/provide...
Watch video Resource Exports & Dependencies | Terraform Tutorial | #5 online without registration, duration hours minute second in high quality. This video was added by user Will Brock 17 June 2020, don't forget to share it with your friends and acquaintances, it has been viewed on our site 22,642 once and liked it 303 people.