Skip to content

Commit b6ae4ad

Browse files
committed
feat(aws_instance): add instance market options block
1 parent 225880e commit b6ae4ad

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

examples/complete/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ variable "instance_market_options" {
7373
EOT
7474
default = null
7575
validation {
76-
condition = contains(["spot", "capacity-block"], var.instance_market_options.market_type)
76+
condition = var.instance_market_options != null ? contains(["spot", "capacity-block"], var.instance_market_options.market_type) : true
7777
error_message = "The value of market_type must be one of the following: \"spot\" and \"capacity-block\"."
7878
}
7979
}

variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ variable "instance_market_options" {
6262
EOT
6363
default = null
6464
validation {
65-
condition = contains(["spot", "capacity-block"], var.instance_market_options.market_type)
65+
condition = var.instance_market_options != null ? contains(["spot", "capacity-block"], var.instance_market_options.market_type) : true
6666
error_message = "The value of market_type must be one of the following: \"spot\" and \"capacity-block\"."
6767
}
6868
}

0 commit comments

Comments
 (0)