resource address

The type and name of a resource joined by a dot, such as local_file.greeting, which identifies it everywhere.

In more detail

You see addresses in plans, in state, in error messages and in commands that act on one resource. Instances created with count or for_each add an index or key, as in null_resource.subnet["a"], and resources inside modules are prefixed with module and the module name. Changing an address makes Terraform see a different object, which can cause a replacement.

Examples

local_file.greeting
module.network.null_resource.subnet["a"]

Related terms

Taught in

References

Certification courses