How to Generate a Markdown Report¶
This guide shows you how to generate a Markdown report from a Terraform plan JSON file.
Prerequisites¶
tf-peekinstalled (see How to install tf-peek)- A Terraform plan exported to JSON
Produce the Terraform plan JSON¶
If you have not already exported your plan to JSON, do it now:
Generate and print to stdout¶
Pass the JSON file as the positional argument to tf-peek generate:
The Markdown report is printed to stdout. You can pipe it to any tool that accepts Markdown.
Save to a file¶
To write the report to a file instead of printing it, use --output (short form: -o):
If the file already exists, tf-peek will overwrite it and print a notice:
Use a custom configuration file¶
By default tf-peek looks for peek_config.toml in the current working directory.
To point it at a different file, use --config (short form: -c):
If neither the default file nor the specified file exists, tf-peek proceeds with an empty
configuration (all resources are classified as normal).
Combine options¶
Options can be combined freely:
See also¶
- CLI reference — complete argument and option descriptions
- How to silence noisy resource types
- How to flag critical resources