Start here Reviewing plansMenu

Start here

Reviewing plans

Open a saved plan to see what it will do before you apply it:

terraform plan -out=tfplan
infraglass serve --plan-file tfplan

Or use the JSON directly: terraform show -json tfplan > plan.json and infraglass serve --plan plan.json.

Reading the picture

Every resource carries its planned action:

Mark Action
green + create
amber ~ update in place
orange ± replace (destroy and create)
red − delete
blue ↻ read (a data source)

The sidebar's Plan card counts each action. Click one to show only those resources. Values Terraform can't know yet appear as (known after apply).

What changes, attribute by attribute

For each update and replace, the Overview tab lists every changed attribute with its old value struck through and its new value beside it. Attributes that force the replacement are marked forces replacement, so you can see at once why a resource will be recreated.

Infraglass compares the real values, so a changed secret shows up as a change, but the value itself stays hidden as (sensitive). When a whole object becomes unknown, it's shown as one change, the way terraform plan shows it.

What to look at first

The sidebar's Review first card lists the risks Infraglass found in the plan, highest first. Click one to open the resource.

Severity Risk
high a resource that holds data is replaced or deleted: a database, bucket, table, key, volume, file system, cache, queue, stream, secret, log group, registry or similar
high a precondition, postcondition, check block or variable validation failed or errored
high a create or update brings in a high-severity access finding
medium a resource that others depend on is replaced or deleted (it names how many)
medium a resource changed outside Terraform (drift)
low a check that Terraform can only evaluate during apply

Blast radius

Each resource's Overview shows its blast radius: how many resources depend on it, directly and through others, by reference, depends_on or a shared value. Show on graph highlights them and dims everything else, so you can see what a replacement could disturb.

A DynamoDB table and its blast radius: the resources that depend on it, highlighted on the graph

Drift and checks

When the plan refreshed state, Terraform records what changed outside it. Infraglass counts an attribute as drift only when a value Terraform had recorded changed or disappeared. A refresh also fills in what was empty (tags going from null to {}, a role's attached policy list, a security group's rules from separate rule resources), and that isn't shown. Drifted resources carry a drifted mark, and their Overview shows Changed outside Terraform with the attributes that moved. Check results (preconditions, postconditions, check blocks and variable validations) appear as Conditions on the resource they belong to, with the error message Terraform gave.

Comparing two snapshots

To see what changed between two states, two plans, or a state and a plan:

infraglass compare before.json after.json            # text
infraglass compare --format markdown before.json after.json

Sharing a review

Post a summary on the pull request, or attach a full interactive copy:

infraglass export --dir . --plan-file tfplan --format markdown > plan.md
infraglass export --dir . --plan-file tfplan -o plan.html

See CI and pipelines for the GitHub Action, gates and exit codes.

Improve this page on GitHub · Report a problem