How do outputs work between modules and what can you set on them?
IntermediateConceptVariables, Locals, Outputs and Types
Answer
A child module's outputs are read as module.<name>.<output>. An output can be sensitive, can have depends_on (rarely needed) and, since 1.2, precondition blocks to validate before exposing. Only outputs are visible outside a module; internal resources are not addressable from the caller.
More on Variables, Locals, Outputs and Types
How do you declare an input variable?BeginnerIn what order does Terraform load variable values?BeginnerHow do you define an output and what is it for?BeginnerWhat is the difference between locals and variables?BeginnerWhat are the primitive types in Terraform?BeginnerHow do list, set and map differ?Intermediate