Refactor storage account variable names for clarity and consistency
This commit is contained in:
10
variables.tf
10
variables.tf
@@ -6,21 +6,21 @@ variable "location" {
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "storage_account_base_name" {
|
||||
variable "base_name" {
|
||||
type = string
|
||||
default = null
|
||||
}
|
||||
|
||||
variable "storage_account_name" {
|
||||
variable "name" {
|
||||
type = string
|
||||
default = null
|
||||
|
||||
validation {
|
||||
condition = (
|
||||
(var.storage_account_name != null && trimspace(var.storage_account_name) != "") ||
|
||||
(var.storage_account_base_name != null && trimspace(var.storage_account_base_name) != "")
|
||||
(var.name != null && trimspace(var.name) != "") ||
|
||||
(var.base_name != null && trimspace(var.base_name) != "")
|
||||
)
|
||||
error_message = "Provide storage_account_name or storage_account_base_name with a non-empty value."
|
||||
error_message = "Provide name or base_name with a non-empty value."
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user