DevOps / Scripts bash Intermediate

Terraform Plan Summary

Run terraform plan and extract only the resource diff line for PR comments.

bash
#!/bin/bash
terraform plan -compact-warnings -input=false 2>&1 | grep -E 'Plan:|No changes|Error'

Prerequisites

  • terraform >= 1.0

Pro Tips

  • → Save plan with -out for consistency.

Was this module useful?

Share your experience — it helps the team improve.

Leave Feedback

Commercial Licensing

Acquire a production access token or template license for enterprise deployment.

Module Info

Language
bash
Level
Intermediate
Read time
2 min
Published
Apr 2024
License
Commercial License

Newsletter

New modules every week, directly to your inbox.