From 7d0017879e720046203f56594e9a2bb3ae331a2e Mon Sep 17 00:00:00 2001 From: Vitaliy Emporopulo Date: Sun, 2 Oct 2022 19:47:56 +0300 Subject: [PATCH 1/2] Upgrade to TF 1.3.x --- variables.tf | 6 ++---- versions.tf | 3 +-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/variables.tf b/variables.tf index 83b64ce..c8a0697 100644 --- a/variables.tf +++ b/variables.tf @@ -50,7 +50,7 @@ variable "private_subnets" { vsphere_service_type = string, routable = bool, cidr = string, - reserved_ip_count = optional(number) + reserved_ip_count = optional(number, 100) })) default = [ { @@ -58,8 +58,7 @@ variable "private_subnets" { "nat" : true, "vsphere_service_type" : "management", "routable" : true, - "cidr" : "172.16.0.0/24", - "reserved_ip_count" : 100 + "cidr" : "172.16.0.0/24" }, { "name" : "vMotion", @@ -91,7 +90,6 @@ variable "public_subnets" { { "name" : "VM Public Net 1", "nat" : false, - "vsphere_service_type" : null, "routable" : true, "ip_count" : 8 } diff --git a/versions.tf b/versions.tf index cdd5fb9..c5cb721 100644 --- a/versions.tf +++ b/versions.tf @@ -1,5 +1,4 @@ terraform { - experiments = [module_variable_optional_attrs] required_providers { null = { source = "hashicorp/null" @@ -21,5 +20,5 @@ terraform { source = "hashicorp/local" } } - required_version = ">= 0.14" + required_version = ">= 1.3.0" } From 16b086419028ce0bdd70a5765e1db5df2046f77e Mon Sep 17 00:00:00 2001 From: Vitaliy Emporopulo Date: Mon, 7 Nov 2022 09:10:16 +0200 Subject: [PATCH 2/2] Make vSphere service type optional --- variables.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/variables.tf b/variables.tf index c8a0697..443b894 100644 --- a/variables.tf +++ b/variables.tf @@ -47,7 +47,7 @@ variable "private_subnets" { type = list(object({ name = string, nat = bool, - vsphere_service_type = string, + vsphere_service_type = optional(string), routable = bool, cidr = string, reserved_ip_count = optional(number, 100)