From b3c1f7e8802d2c9c6b07f6a773fe20d3fef6c90a Mon Sep 17 00:00:00 2001 From: anniehedgpeth Date: Fri, 15 Sep 2023 09:43:44 -0600 Subject: [PATCH] remove defaults in lb vars --- main.tf | 1 + modules/load_balancer/variables.tf | 20 +------------------- variables.tf | 10 ++++++++-- 3 files changed, 10 insertions(+), 21 deletions(-) diff --git a/main.tf b/main.tf index 16848cf8..17c20d0b 100644 --- a/main.tf +++ b/main.tf @@ -351,6 +351,7 @@ module "load_balancer" { load_balancer_type = var.load_balancer_type load_balancer_public = var.load_balancer_public load_balancer_request_routing_rule_minimum_priority = var.load_balancer_request_routing_rule_minimum_priority + load_balancer_sku_capacity = var.load_balancer_sku_capacity load_balancer_sku_name = var.load_balancer_sku_name load_balancer_sku_tier = var.load_balancer_sku_tier load_balancer_waf_firewall_mode = var.load_balancer_waf_firewall_mode diff --git a/modules/load_balancer/variables.tf b/modules/load_balancer/variables.tf index 8f422746..05c1e314 100644 --- a/modules/load_balancer/variables.tf +++ b/modules/load_balancer/variables.tf @@ -19,13 +19,11 @@ variable "is_legacy_deployment" { } variable "tfe_subdomain" { - default = null type = string description = "Subdomain for TFE" } variable "active_active" { - default = true type = bool description = "True if TFE running in active-active configuration" } @@ -38,13 +36,11 @@ variable "enable_ssh" { # DNS # --- variable "dns_create_record" { - default = true type = bool description = "If true, will create a DNS record. If false, no record will be created and IP of load balancer will instead be output." } variable "dns_external_fqdn" { - default = null type = string description = "External DNS FQDN should be supplied if dns_create_record is false" } @@ -57,7 +53,6 @@ variable "location" { } variable "zones" { - default = ["1", "2", "3"] type = list(string) description = "Azure zones to use for applicable resources" } @@ -97,7 +92,6 @@ variable "ca_certificate_secret" { # Load balancer # ------------- variable "load_balancer_type" { - default = "application_gateway" type = string description = "Expected value of 'application_gateway' or 'load_balancer'" @@ -112,19 +106,16 @@ variable "load_balancer_type" { } variable "load_balancer_public" { - default = true type = bool description = "Load balancer will use public IP if true" } variable "load_balancer_enable_http2" { - default = true type = bool description = "Determine if HTTP2 enabled on Application Gateway" } variable "load_balancer_sku_name" { - default = "Standard_v2" type = string description = "The Name of the SKU to use for Application Gateway, Standard_v2 or WAF_v2 accepted" @@ -139,7 +130,6 @@ variable "load_balancer_sku_name" { } variable "load_balancer_sku_tier" { - default = "Standard_v2" type = string description = "The Tier of the SKU to use for Application Gateway, Standard_v2 or WAF_v2 accepted" @@ -154,37 +144,31 @@ variable "load_balancer_sku_tier" { } variable "load_balancer_waf_firewall_mode" { - default = "Prevention" type = string description = "The Web Application Firewall mode (Detection or Prevention)" } variable "load_balancer_waf_rule_set_version" { - default = "3.1" type = string - description = "The Version of the Rule Set used for this Web Application Firewall. Possible values are 2.2.9, 3.0, and 3.1." + description = "The Version of the Rule Set used for this Web Application Firewall. Possible values are 2.2.9, 3.0, 3.1, and 3.2." } variable "load_balancer_waf_file_upload_limit_mb" { - default = 100 type = number description = "The File Upload Limit in MB. Accepted values are in the range 1MB to 750MB for the WAF_v2 SKU, and 1MB to 500MB for all other SKUs. Defaults to 100MB." } variable "load_balancer_waf_max_request_body_size_kb" { - default = 128 type = number description = "The Maximum Request Body Size in KB. Accepted values are in the range 1KB to 128KB. Defaults to 128KB." } variable "load_balancer_sku_capacity" { - default = 2 type = number description = "The Capacity of the SKU to use for Application Gateway (1 to 125)" } variable "load_balancer_request_routing_rule_minimum_priority" { - default = 1000 type = number description = "The minimum priority for request routing rule. Lower priotity numbered rules take precedence over higher priotity number rules." validation { @@ -204,7 +188,6 @@ variable "network_frontend_subnet_id" { } variable "network_private_ip" { - default = null type = string description = "(optional) Private IP address to use for LB/AG endpoint" } @@ -216,7 +199,6 @@ variable "network_frontend_subnet_cidr" { # Tagging variable "tags" { - default = {} type = map(string) description = "Map of tags for resource" } diff --git a/variables.tf b/variables.tf index d5e90d0f..e5d6be84 100644 --- a/variables.tf +++ b/variables.tf @@ -402,6 +402,12 @@ variable "load_balancer_request_routing_rule_minimum_priority" { } } +variable "load_balancer_sku_capacity" { + default = 2 + type = number + description = "The Capacity of the SKU to use for Application Gateway (1 to 125)" +} + variable "load_balancer_sku_name" { default = "Standard_v2" type = string @@ -439,9 +445,9 @@ variable "load_balancer_waf_firewall_mode" { } variable "load_balancer_waf_rule_set_version" { - default = "3.1" + default = "3.2" type = string - description = "The Version of the Rule Set used for this Web Application Firewall. Possible values are 2.2.9, 3.0, and 3.1." + description = "The Version of the Rule Set used for this Web Application Firewall. Possible values are 2.2.9, 3.0, 3.1, and 3.2." } variable "load_balancer_waf_file_upload_limit_mb" {