Terraform Guide

Inframap alternative: past pruned DOT, toward a diagram people actually keep

Inframap had the right diagnosis: the raw Terraform graph is unreadable, so prune it down to the resources that matter. If you live in a terminal and want a quick one-off picture, it still earns its stars. The gaps show up the day the diagram needs an audience: DOT output, no module structure, no doc, and nothing keeping it current after the next merge.

6 min readFor engineers comparing Terraform visualization tools before standardizing on one

See it as a diagram

Everything below, as a diagram you can edit. Describe yours and see it in seconds.

168/20003 credits left
Try:

No account needed · Editable canvas, not a picture

Where the CLI generation of tools stops

Inframap, terravision, and the terraform graph pipeline share a shape: run a command, get a DOT or image artifact, paste it somewhere. Pruning quality differs, but three limits are structural. The output has no module zones, so a well-factored repo loses exactly the structure its authors built. The artifact is static, so it is stale after the next merge unless someone re-runs and re-pastes. And there is no companion doc, so the picture floats without the paragraph that explains it.

State-based modes add the access problem: pointing a visualization tool at terraform state means handing it resource ids and whatever secrets providers wrote there.

What Datadef does differently

The parse is source-only and repository-shaped: every .tf file, stacks, modules, resources, references resolved through outputs, per-environment counts from tfvars, registry modules with versions. No state, no init, read-only access.

The output is a curated canvas, not DOT: modules as zones, provider icons on the resources, identity wiring summarized instead of drawn, and a companion architecture doc with a generated module reference table. Node identity is stable across syncs, so the picture updates rather than reshuffles.

And it stays current on its own: daily sync plus on-demand refresh, with a live embed for the README so the shared picture is always the current one. That last property is the one no run-once CLI can offer.

When the CLI tool is still the right call

For a throwaway picture of a small stack during a code review, a local CLI is faster than connecting anything, and no account is a feature. The switch point is audience and lifetime: the moment a diagram needs to be seen by people who do not run CLIs, or needs to still be true next month, generation has to move from a one-off command to a synced service.

FAQ

Does Datadef read terraform state like inframap can?

No, deliberately. The parse is source-only: the .tf and .tfvars files of the connected repository. That avoids handing state, which can contain ids and secrets, to a third party, and it works with read-only repo access.

Inframap prunes the graph. How does Datadef decide what to show?

Deterministic curation during analysis: major resources stay individual nodes, repeated minor types roll up with counts, identity wiring becomes a note, and module structure becomes zones. The full inventory remains in the generated module reference table.

Can the output be committed to the repo like a generated image?

Better: embed the live image URL in the README. It renders the current diagram and updates on every sync, so there is no generated file to regenerate and re-commit.

Is there a way to trigger regeneration from CI or an agent?

Yes. The MCP server exposes repo status and refresh tools, so a coding agent or a CI step can check freshness and trigger a re-sync after infrastructure changes merge.