Remove preemptible VMs in favor of spot VMs

This commit is contained in:
Julio Castillo
2022-05-04 18:01:07 +02:00
parent c0bd3d3ea9
commit e6135bb323
3 changed files with 17 additions and 24 deletions

View File

@@ -189,19 +189,13 @@ variable "options" {
type = object({
allow_stopping_for_update = bool
deletion_protection = bool
preemptible = bool
spot = bool
})
default = {
allow_stopping_for_update = true
deletion_protection = false
preemptible = false
spot = false
}
validation {
condition = !var.options.spot || (var.options.spot && var.options.preemptible)
error_message = "Variable var.option.preemptible must be `true` when var.options.spot is set to `true`."
}
}
variable "project_id" {