Skip to content
This repository has been archived by the owner on Aug 23, 2024. It is now read-only.

Simplify private_subnets variable with appropriate defaults #57

Merged
merged 4 commits into from
Jun 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -47,19 +47,18 @@ 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)
reserved_ip_count = optional(number, 100)
displague marked this conversation as resolved.
Show resolved Hide resolved
}))
default = [
{
"name" : "VM Private Net 1",
"nat" : true,
"vsphere_service_type" : "management",
"routable" : true,
"cidr" : "172.16.0.0/24",
"reserved_ip_count" : 100
displague marked this conversation as resolved.
Show resolved Hide resolved
"cidr" : "172.16.0.0/24"
},
{
"name" : "vMotion",
Expand Down Expand Up @@ -91,7 +90,6 @@ variable "public_subnets" {
{
"name" : "VM Public Net 1",
"nat" : false,
"vsphere_service_type" : null,
"routable" : true,
"ip_count" : 8
}
Expand Down
2 changes: 2 additions & 0 deletions versions.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
terraform {
required_version = "~> 1.4"

required_providers {
null = {
source = "hashicorp/null"
Expand All @@ -21,6 +22,7 @@ terraform {
source = "hashicorp/local"
}
}

provider_meta "equinix" {
module_name = "equinix-metal-vsphere"
}
Expand Down
Loading