diff --git a/modules/aws/agentless-gw/variables.tf b/modules/aws/agentless-gw/variables.tf index 6da68c2ae..023a20a4c 100644 --- a/modules/aws/agentless-gw/variables.tf +++ b/modules/aws/agentless-gw/variables.tf @@ -169,8 +169,8 @@ variable "password" { sensitive = true description = "Initial password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } } diff --git a/modules/aws/hub/variables.tf b/modules/aws/hub/variables.tf index 2b4050019..5188d3f8d 100644 --- a/modules/aws/hub/variables.tf +++ b/modules/aws/hub/variables.tf @@ -183,8 +183,8 @@ variable "password" { sensitive = true description = "Initial password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } } diff --git a/modules/aws/sonar-base-instance/variables.tf b/modules/aws/sonar-base-instance/variables.tf index c64f36f4f..af9872d14 100644 --- a/modules/aws/sonar-base-instance/variables.tf +++ b/modules/aws/sonar-base-instance/variables.tf @@ -112,8 +112,8 @@ variable "password" { sensitive = true description = "Password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } } diff --git a/modules/azurerm/agentless-gw/variables.tf b/modules/azurerm/agentless-gw/variables.tf index 6ccd092e1..07b4fcc8f 100644 --- a/modules/azurerm/agentless-gw/variables.tf +++ b/modules/azurerm/agentless-gw/variables.tf @@ -160,8 +160,8 @@ variable "password" { sensitive = true description = "Initial password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } } diff --git a/modules/azurerm/hub/variables.tf b/modules/azurerm/hub/variables.tf index 04c455d41..decbca590 100644 --- a/modules/azurerm/hub/variables.tf +++ b/modules/azurerm/hub/variables.tf @@ -180,8 +180,8 @@ variable "password" { sensitive = true description = "Initial password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } } diff --git a/modules/azurerm/sonar-base-instance/variables.tf b/modules/azurerm/sonar-base-instance/variables.tf index 05fea95b5..2e2e4fa9f 100644 --- a/modules/azurerm/sonar-base-instance/variables.tf +++ b/modules/azurerm/sonar-base-instance/variables.tf @@ -109,8 +109,8 @@ variable "password" { sensitive = true description = "Password for all users" validation { - condition = var.password == null || try(length(var.password) > 8, false) - error_message = "Must be at least 8 characters. Used only if 'password_secret_name' is not set." + condition = var.password == null || try(length(var.password) >= 7, false) + error_message = "Must be at least 7 characters. Used only if 'password_secret_name' is not set." } }