Outputting Resource Properties
Explore how to use Terraform outputs to display key resource properties, such as an S3 bucket name and ARN, after your Terraform run completes. Understand how to define outputs and see them in your project outputs. Practice creating and destroying resources while managing output data effectively.
We'll cover the following...
We'll cover the following...
The first example is pretty basic and, in the real world, probably not very useful. Outputs are much more useful when used to output the values of resources that have been created as part of a Terraform run.
Terraform output project example
Let’s create another Terraform project and output the values of resources as a part of a Terraform run:
Let’s walk through the above code.
-
The
providerandresourceshould be familiar to you. We are simply ...