Terraform plan file to JSON
Utility to read in a Terraform plan file and dump it out in JSON. Standalone version of Terraform PR #3170.
$ go get github.com/palantir/tfjsonGiven the following Terraform resources:
provider "aws" {
region = "us-east-1"
}
resource "aws_vpc" "main" {
cidr_block = "10.0.0.0/16"
}
module "inner" {
source = "./inner"
}
// in inner module:
resource "aws_vpc" "inner" {
cidr_block = "10.0.0.0/8"
}Running terraform plan -out=terraform.tfplan produces a Terraform plan file.
The JSON representation produced by tfjson looks like:
…This project is made available under the MIT License.
No open issues yet, or sync has not completed.