Troubleshooting
Terraform
Occassionally, the terraform
command does not behave as expected. In certain situations it can be helpful to enable Terraform debugging giving detailed logs useful for troubleshooting.
To enable Terraform debugging against a Terrateam run, set up the following hooks in your Terrateam configuration file .terrateam/config.yml
.
hooks:
plan:
pre:
- type: env
name: TF_LOG
cmd: ['echo', 'DEBUG']
post: []
apply:
pre:
- type: env
name: TF_LOG
cmd: ['echo', 'DEBUG']
post: []
Once these changes are pushed to your branch, Terrateam will execute terraform
in debug mode TF_LOG=DEBUG
exposing lots of information for the plan and apply.
Terraform debugging produces a lot of output.
For more information on debugging Terraform, please see the official Hashicorp Terraform documentation.
Terrateam
To view logs from a Terrateam operation:
-
Navigate to the main page of your Terraform repository on GitHub and select
Actions
-
Select the
Terrateam Workflow
run you’d like to investigate -
Select
Terrateam Action
-
Expand
Run Terrateam Action
If you need help investigating a Terrateam workflow run, please join our Slack community.