Search resources in state
Filter the resources in state by a pattern
terraform state list | grep <pattern>
More terraform commands
-
terraform fmt -recursiveFormat all .tf files, including subdirectories
-
terraform validateCheck the Terraform configuration for syntax and consistency errors
-
terraform plan -var-file=prod.tfvars -out=prod.tfplanBuild a plan with prod variables and save it to a file
-
terraform apply prod.tfplanApply exactly the plan you saved before, without a second confirmation
-
terraform state show 'aws_instance.web[0]'Show all attributes of one resource in state