├── .editorconfig ├── .github ├── dependabot.yml └── workflows │ ├── ci.yaml │ └── release.yaml ├── .gitignore ├── .golangci.yaml ├── .goreleaser.yml ├── .revive.toml ├── Dockerfile ├── LICENSE ├── README.md ├── cmd └── gotf │ ├── gotf.go │ ├── gotf_test.go │ └── testdata │ ├── 01_networking │ ├── dev.tfvars │ ├── prod.tfvars │ └── test.tf │ ├── 02_compute │ ├── dev.tfvars │ ├── prod.tfvars │ └── test.tf │ ├── dev.env │ ├── global-dev.tfvars │ ├── global-prod.tfvars │ ├── global.tfvars │ ├── prod.env │ └── test-config.yaml ├── demo ├── 01_first │ ├── main.tf │ ├── outputs.tf │ ├── provider.tf │ ├── terraform.tf │ ├── tf.plan │ ├── variables.tf │ ├── vars-dev.tfvars │ └── vars-prod.tfvars ├── 02_second │ ├── main.tf │ ├── outputs.tf │ ├── provider.tf │ ├── terraform.tf │ ├── variables.tf │ ├── vars-dev.tfvars │ └── vars-prod.tfvars ├── global-vars-dev.tfvars ├── global-vars-prod.tfvars └── gotf.yaml ├── go.mod ├── go.sum ├── magefile.go ├── main.go └── pkg ├── config ├── config.go ├── config_test.go └── testdata │ ├── dev.env │ ├── global-dev.tfvars │ ├── global-prod.tfvars │ ├── global.tfvars │ ├── prod.env │ ├── test-config.yaml │ ├── testmodule1 │ ├── test1-dev.tfvars │ ├── test1-prod.tfvars │ ├── test2-dev.tfvars │ └── test2-prod.tfvars │ └── testmodule2 │ ├── test1-dev.tfvars │ ├── test1-prod.tfvars │ ├── test2-dev.tfvars │ └── test2-prod.tfvars ├── gotf ├── gotf.go ├── gpg_key_new.txt └── gpg_key_old.txt ├── opts └── opts.go ├── sh └── sh.go └── tf ├── installer.go ├── installer_test.go ├── terraform.go └── testdata ├── test_0.42.0_SHA256SUMS ├── test_0.42.0_SHA256SUMS.sig ├── test_0.42.0_darwin_amd64.zip ├── test_0.42.0_linux_amd64.zip └── test_0.42.0_windows_amd64.zip /.editorconfig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.editorconfig -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.github/dependabot.yml -------------------------------------------------------------------------------- /.github/workflows/ci.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.github/workflows/ci.yaml -------------------------------------------------------------------------------- /.github/workflows/release.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.github/workflows/release.yaml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.gitignore -------------------------------------------------------------------------------- /.golangci.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.golangci.yaml -------------------------------------------------------------------------------- /.goreleaser.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.goreleaser.yml -------------------------------------------------------------------------------- /.revive.toml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/.revive.toml -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/Dockerfile -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/README.md -------------------------------------------------------------------------------- /cmd/gotf/gotf.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/gotf.go -------------------------------------------------------------------------------- /cmd/gotf/gotf_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/gotf_test.go -------------------------------------------------------------------------------- /cmd/gotf/testdata/01_networking/dev.tfvars: -------------------------------------------------------------------------------- 1 | bar = "module1_dev" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/01_networking/prod.tfvars: -------------------------------------------------------------------------------- 1 | bar = "module1_prod" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/01_networking/test.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/testdata/01_networking/test.tf -------------------------------------------------------------------------------- /cmd/gotf/testdata/02_compute/dev.tfvars: -------------------------------------------------------------------------------- 1 | bar = "module2_dev" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/02_compute/prod.tfvars: -------------------------------------------------------------------------------- 1 | bar = "module2_prod" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/02_compute/test.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/testdata/02_compute/test.tf -------------------------------------------------------------------------------- /cmd/gotf/testdata/dev.env: -------------------------------------------------------------------------------- 1 | VAR_FROM_ENV_FILE=dev-env 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/global-dev.tfvars: -------------------------------------------------------------------------------- 1 | env_specific_var = "devvalue" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/global-prod.tfvars: -------------------------------------------------------------------------------- 1 | env_specific_var = "prodvalue" 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/global.tfvars: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/testdata/global.tfvars -------------------------------------------------------------------------------- /cmd/gotf/testdata/prod.env: -------------------------------------------------------------------------------- 1 | VAR_FROM_ENV_FILE=prod-env 2 | -------------------------------------------------------------------------------- /cmd/gotf/testdata/test-config.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/cmd/gotf/testdata/test-config.yaml -------------------------------------------------------------------------------- /demo/01_first/main.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/01_first/main.tf -------------------------------------------------------------------------------- /demo/01_first/outputs.tf: -------------------------------------------------------------------------------- 1 | output "bar" { 2 | value = random_string.bar.result 3 | } 4 | -------------------------------------------------------------------------------- /demo/01_first/provider.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/01_first/provider.tf -------------------------------------------------------------------------------- /demo/01_first/terraform.tf: -------------------------------------------------------------------------------- 1 | terraform { 2 | required_version = "~> 1.0.9" 3 | backend "local" {} 4 | } 5 | -------------------------------------------------------------------------------- /demo/01_first/tf.plan: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/01_first/tf.plan -------------------------------------------------------------------------------- /demo/01_first/variables.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/01_first/variables.tf -------------------------------------------------------------------------------- /demo/01_first/vars-dev.tfvars: -------------------------------------------------------------------------------- 1 | use_special_chars = false 2 | -------------------------------------------------------------------------------- /demo/01_first/vars-prod.tfvars: -------------------------------------------------------------------------------- 1 | use_special_chars = true 2 | -------------------------------------------------------------------------------- /demo/02_second/main.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/02_second/main.tf -------------------------------------------------------------------------------- /demo/02_second/outputs.tf: -------------------------------------------------------------------------------- 1 | output "foo" { 2 | value = random_string.foo.result 3 | } 4 | -------------------------------------------------------------------------------- /demo/02_second/provider.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/02_second/provider.tf -------------------------------------------------------------------------------- /demo/02_second/terraform.tf: -------------------------------------------------------------------------------- 1 | terraform { 2 | required_version = "~> 1.0.9" 3 | backend "local" {} 4 | } 5 | -------------------------------------------------------------------------------- /demo/02_second/variables.tf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/02_second/variables.tf -------------------------------------------------------------------------------- /demo/02_second/vars-dev.tfvars: -------------------------------------------------------------------------------- 1 | random_string_length = 10 2 | -------------------------------------------------------------------------------- /demo/02_second/vars-prod.tfvars: -------------------------------------------------------------------------------- 1 | random_string_length = 20 2 | -------------------------------------------------------------------------------- /demo/global-vars-dev.tfvars: -------------------------------------------------------------------------------- 1 | global_message = "Spinning up development infrastructure" 2 | -------------------------------------------------------------------------------- /demo/global-vars-prod.tfvars: -------------------------------------------------------------------------------- 1 | global_message = "Spinning up production infrastructure" 2 | -------------------------------------------------------------------------------- /demo/gotf.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/demo/gotf.yaml -------------------------------------------------------------------------------- /go.mod: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/go.mod -------------------------------------------------------------------------------- /go.sum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/go.sum -------------------------------------------------------------------------------- /magefile.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/magefile.go -------------------------------------------------------------------------------- /main.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/main.go -------------------------------------------------------------------------------- /pkg/config/config.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/config/config.go -------------------------------------------------------------------------------- /pkg/config/config_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/config/config_test.go -------------------------------------------------------------------------------- /pkg/config/testdata/dev.env: -------------------------------------------------------------------------------- 1 | MY_ENV=dev-env 2 | -------------------------------------------------------------------------------- /pkg/config/testdata/global-dev.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/global-prod.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/global.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/prod.env: -------------------------------------------------------------------------------- 1 | MY_ENV=prod-env 2 | -------------------------------------------------------------------------------- /pkg/config/testdata/test-config.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/config/testdata/test-config.yaml -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule1/test1-dev.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule1/test1-prod.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule1/test2-dev.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule1/test2-prod.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule2/test1-dev.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule2/test1-prod.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule2/test2-dev.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/config/testdata/testmodule2/test2-prod.tfvars: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /pkg/gotf/gotf.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/gotf/gotf.go -------------------------------------------------------------------------------- /pkg/gotf/gpg_key_new.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/gotf/gpg_key_new.txt -------------------------------------------------------------------------------- /pkg/gotf/gpg_key_old.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/gotf/gpg_key_old.txt -------------------------------------------------------------------------------- /pkg/opts/opts.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/opts/opts.go -------------------------------------------------------------------------------- /pkg/sh/sh.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/sh/sh.go -------------------------------------------------------------------------------- /pkg/tf/installer.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/installer.go -------------------------------------------------------------------------------- /pkg/tf/installer_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/installer_test.go -------------------------------------------------------------------------------- /pkg/tf/terraform.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/terraform.go -------------------------------------------------------------------------------- /pkg/tf/testdata/test_0.42.0_SHA256SUMS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/testdata/test_0.42.0_SHA256SUMS -------------------------------------------------------------------------------- /pkg/tf/testdata/test_0.42.0_SHA256SUMS.sig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/testdata/test_0.42.0_SHA256SUMS.sig -------------------------------------------------------------------------------- /pkg/tf/testdata/test_0.42.0_darwin_amd64.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/testdata/test_0.42.0_darwin_amd64.zip -------------------------------------------------------------------------------- /pkg/tf/testdata/test_0.42.0_linux_amd64.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/testdata/test_0.42.0_linux_amd64.zip -------------------------------------------------------------------------------- /pkg/tf/testdata/test_0.42.0_windows_amd64.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/craftypath/gotf/HEAD/pkg/tf/testdata/test_0.42.0_windows_amd64.zip --------------------------------------------------------------------------------