Terraform Quick Reference

Quick reference for Terraform when using AWS.

export AWS_PROFILE=<name of AWS Profile>

aws sso login --profile=$AWS_PROFILE

Once you are authenticated, i’m assuming SSO here, then you can apply your configuration with:

terraform init

terraform validate

terraform plan

terraform apply

terraform destroy

You can add the “–auto-approve” to the end so you don’t have to press “yes”, but use with caution!

Leave a comment