This Terraform provides allows to log text or data structures to a file for debug purposes.
This provider plugin is maintained by Sedicii.
curl https://raw.githubusercontent.com/Sedicii/terraform-provider-debug/master/scripts/install-debug-tf-pluging.sh | bash
provider "debug" {
log_file = "<path to log file>" // Default to "/tmp/tf-debug-provider.log"
}
locals {
data = {
test = 1
bla = "test"
}
}
data "debug_log" "log" {
line = "bla value is ${local.data.bla}" // type string, for log lines
data = "${local.data}" // type map, for data structures
tag = "some_tag" // will appear in the log line. Default to "default"
}