From 79127dd2c4f8edd8c2e3b0f4ca223b9402a6f9fa Mon Sep 17 00:00:00 2001 From: Jean-Marc Fontaine Date: Fri, 9 Jun 2023 16:22:35 -0400 Subject: [PATCH] Explicitly require Terraform and provider versions --- .gitignore | 1 - exporters/tfc/.terraform.lock.hcl | 59 +++++++++++++++++++++++++++++++ exporters/tfc/main.tf | 19 ++++++++++ generator/.terraform.lock.hcl | 21 +++++++++++ generator/main.tf | 11 ++++++ manager-stack/.terraform.lock.hcl | 16 +++++++++ 6 files changed, 126 insertions(+), 1 deletion(-) create mode 100644 exporters/tfc/.terraform.lock.hcl create mode 100644 generator/.terraform.lock.hcl create mode 100644 manager-stack/.terraform.lock.hcl diff --git a/.gitignore b/.gitignore index 6b06ae7..a136526 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,4 @@ .terraform -.terraform.lock.hcl terraform.tfstate* *.tfvars !*.example.tfvars diff --git a/exporters/tfc/.terraform.lock.hcl b/exporters/tfc/.terraform.lock.hcl new file mode 100644 index 0000000..46924de --- /dev/null +++ b/exporters/tfc/.terraform.lock.hcl @@ -0,0 +1,59 @@ +# This file is maintained automatically by "terraform init". +# Manual edits may be lost in future updates. + +provider "registry.terraform.io/hashicorp/local" { + version = "2.4.0" + hashes = [ + "h1:ZUEYUmm2t4vxwzxy1BvN1wL6SDWrDxfH7pxtzX8c6d0=", + "zh:53604cd29cb92538668fe09565c739358dc53ca56f9f11312b9d7de81e48fab9", + "zh:66a46e9c508716a1c98efbf793092f03d50049fa4a83cd6b2251e9a06aca2acf", + "zh:70a6f6a852dd83768d0778ce9817d81d4b3f073fab8fa570bff92dcb0824f732", + "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", + "zh:82a803f2f484c8b766e2e9c32343e9c89b91997b9f8d2697f9f3837f62926b35", + "zh:9708a4e40d6cc4b8afd1352e5186e6e1502f6ae599867c120967aebe9d90ed04", + "zh:973f65ce0d67c585f4ec250c1e634c9b22d9c4288b484ee2a871d7fa1e317406", + "zh:c8fa0f98f9316e4cfef082aa9b785ba16e36ff754d6aba8b456dab9500e671c6", + "zh:cfa5342a5f5188b20db246c73ac823918c189468e1382cb3c48a9c0c08fc5bf7", + "zh:e0e2b477c7e899c63b06b38cd8684a893d834d6d0b5e9b033cedc06dd7ffe9e2", + "zh:f62d7d05ea1ee566f732505200ab38d94315a4add27947a60afa29860822d3fc", + "zh:fa7ce69dde358e172bd719014ad637634bbdabc49363104f4fca759b4b73f2ce", + ] +} + +provider "registry.terraform.io/hashicorp/null" { + version = "3.2.1" + hashes = [ + "h1:ydA0/SNRVB1o95btfshvYsmxA+jZFRZcvKzZSB+4S1M=", + "zh:58ed64389620cc7b82f01332e27723856422820cfd302e304b5f6c3436fb9840", + "zh:62a5cc82c3b2ddef7ef3a6f2fedb7b9b3deff4ab7b414938b08e51d6e8be87cb", + "zh:63cff4de03af983175a7e37e52d4bd89d990be256b16b5c7f919aff5ad485aa5", + "zh:74cb22c6700e48486b7cabefa10b33b801dfcab56f1a6ac9b6624531f3d36ea3", + "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", + "zh:79e553aff77f1cfa9012a2218b8238dd672ea5e1b2924775ac9ac24d2a75c238", + "zh:a1e06ddda0b5ac48f7e7c7d59e1ab5a4073bbcf876c73c0299e4610ed53859dc", + "zh:c37a97090f1a82222925d45d84483b2aa702ef7ab66532af6cbcfb567818b970", + "zh:e4453fbebf90c53ca3323a92e7ca0f9961427d2f0ce0d2b65523cc04d5d999c2", + "zh:e80a746921946d8b6761e77305b752ad188da60688cfd2059322875d363be5f5", + "zh:fbdb892d9822ed0e4cb60f2fedbdbb556e4da0d88d3b942ae963ed6ff091e48f", + "zh:fca01a623d90d0cad0843102f9b8b9fe0d3ff8244593bd817f126582b52dd694", + ] +} + +provider "registry.terraform.io/hashicorp/tfe" { + version = "0.45.0" + hashes = [ + "h1:kqJWrqVrP+iK/M9UMy4Qdbomqt/3axrOwrduwVO4e2E=", + "zh:1900c32b6b690fd192dd99754ee17caf80ddfedea275c63eb32a1124c802b243", + "zh:1efa077356dbc5f6c3b03f985d49b611e48b7c383b2e360dbc07bbe3ce3e7d56", + "zh:2507b0bcf04efcdc92b7cc5409c58eb02b20a8245dec6ebdeaf230847fdec576", + "zh:4ab28a987cd374c492d8f85b3486f1b7324dbbe7f8a843d01d7d5e7d5d029cb8", + "zh:68ae5f9c6d6755cc533b6a4d61c21d845b839ce3b77d67a6a58d2aa1f702ea30", + "zh:6cab02332d7a4f24f5d77ea2e30b3e2dc87c3549228740acdae91da1a759276f", + "zh:6dec82e974bd4bd786102139dfc8729152e9c314e188da3d8ea1906243867b61", + "zh:7047bbe4f6d0b99eae54865631e52c464031ab1e25349d587b4d078c171a89a0", + "zh:b9aa8b9ed22baf38b11ca420b3f213ee138db75365f385e32a7c631e3968f2d0", + "zh:c658be8e2be75f732e387c4c3c611ec0d49bb08246a44cc000e07eaed93d78cc", + "zh:d95ec293fa70e946b6cd657912b33155f8be3413e6128ed2bfa5a493f788e439", + "zh:f3c06f03a2fd4d3bf8a2644610bfb8772f7ac4a0995b82d1d3076d1b69600657", + ] +} diff --git a/exporters/tfc/main.tf b/exporters/tfc/main.tf index 35ad299..478b0fd 100644 --- a/exporters/tfc/main.tf +++ b/exporters/tfc/main.tf @@ -1,3 +1,22 @@ +terraform { + required_version = "~> 1.2" + + required_providers { + local = { + source = "hashicorp/local" + version = "~> 2.4.0" + } + null = { + source = "hashicorp/null" + version = "~> 3.2.1" + } + tfe = { + source = "hashicorp/tfe" + version = "~> 0.45.0" + } + } +} + locals { stack_ids = [for i, v in data.tfe_workspace_ids.all.ids : v] stack_names = [for i, v in data.tfe_workspace_ids.all.ids : i] diff --git a/generator/.terraform.lock.hcl b/generator/.terraform.lock.hcl new file mode 100644 index 0000000..a1a1545 --- /dev/null +++ b/generator/.terraform.lock.hcl @@ -0,0 +1,21 @@ +# This file is maintained automatically by "terraform init". +# Manual edits may be lost in future updates. + +provider "registry.terraform.io/hashicorp/local" { + version = "2.4.0" + hashes = [ + "h1:ZUEYUmm2t4vxwzxy1BvN1wL6SDWrDxfH7pxtzX8c6d0=", + "zh:53604cd29cb92538668fe09565c739358dc53ca56f9f11312b9d7de81e48fab9", + "zh:66a46e9c508716a1c98efbf793092f03d50049fa4a83cd6b2251e9a06aca2acf", + "zh:70a6f6a852dd83768d0778ce9817d81d4b3f073fab8fa570bff92dcb0824f732", + "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", + "zh:82a803f2f484c8b766e2e9c32343e9c89b91997b9f8d2697f9f3837f62926b35", + "zh:9708a4e40d6cc4b8afd1352e5186e6e1502f6ae599867c120967aebe9d90ed04", + "zh:973f65ce0d67c585f4ec250c1e634c9b22d9c4288b484ee2a871d7fa1e317406", + "zh:c8fa0f98f9316e4cfef082aa9b785ba16e36ff754d6aba8b456dab9500e671c6", + "zh:cfa5342a5f5188b20db246c73ac823918c189468e1382cb3c48a9c0c08fc5bf7", + "zh:e0e2b477c7e899c63b06b38cd8684a893d834d6d0b5e9b033cedc06dd7ffe9e2", + "zh:f62d7d05ea1ee566f732505200ab38d94315a4add27947a60afa29860822d3fc", + "zh:fa7ce69dde358e172bd719014ad637634bbdabc49363104f4fca759b4b73f2ce", + ] +} diff --git a/generator/main.tf b/generator/main.tf index 9185183..7af809d 100644 --- a/generator/main.tf +++ b/generator/main.tf @@ -1,3 +1,14 @@ +terraform { + required_version = "~> 1.2" + + required_providers { + local = { + source = "hashicorp/local" + version = "~> 2.4.0" + } + } +} + locals { # Use custom template file, if present template_file = fileexists("${path.module}/../generator.tftpl") ? "${path.module}/../generator.tftpl" : "${path.module}/generator.tftpl" diff --git a/manager-stack/.terraform.lock.hcl b/manager-stack/.terraform.lock.hcl new file mode 100644 index 0000000..016e6e1 --- /dev/null +++ b/manager-stack/.terraform.lock.hcl @@ -0,0 +1,16 @@ +# This file is maintained automatically by "terraform init". +# Manual edits may be lost in future updates. + +provider "registry.terraform.io/spacelift-io/spacelift" { + version = "1.1.6" + constraints = "~> 1.0" + hashes = [ + "h1:/1q/1KQR62Cq1J6BpYZx48mdr80WL8oHFlbTzmnEHQA=", + "zh:52e36d8f6269278af57be64eac1e794eacddcf0402a53197f5cb141a66535f99", + "zh:601d7f4a6a494863d12cf562fc05809a94269cc13e13e268b89df08c4dab62db", + "zh:78b3fd7db23fd2d91c7f2f465a91232faa7c04796dc3d5119251cf5d3e19ccc3", + "zh:8f1cc224634f93adbc712dd817b4ce7021355e08bf0933932083cc4042c24585", + "zh:90ba8b231292c35430e46312dcebc97063e1b9953c8645a293676e02e33fb7b6", + "zh:dea3ef8667b0d202f6d27803abb7c376f940d1e0bbb94d5e69d1178bb27df5f5", + ] +}