Inspecting State
OpenTF includes some commands for reading and updating state without taking any other actions.
The
opentf state listcommand shows the resource addresses for every resource OpenTF knows about in a configuration, optionally filtered by partial resource address.The
opentf state showcommand displays detailed state data about one resource.The
opentf refreshcommand updates state data to match the real-world condition of the managed resources. This is done automatically during plans and applies, but not when interacting with state directly.