1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/common/tofu-output.md
Coba b2854347d2
tofu: add page (#16031)
Co-authored-by: K.B.Dharun Krishna <kbdharunkrishna@gmail.com>
2025-03-27 23:50:19 +02:00

506 B

tofu output

Export structured data about your OpenTofu resources. More information: https://opentofu.org/docs/cli/commands/output/.

  • With no additional arguments, output will display all outputs for the root module:

tofu output

  • Output only a value with specific name:

tofu output {{name}}

  • Convert the output value to a raw string (useful for shell scripts):

tofu output -raw

  • Format the outputs as a JSON object, with a key per output (useful with jq):

tofu output -json