Skip to content

Commit

Permalink
chore: fix validation error for resource_allocation (#5)
Browse files Browse the repository at this point in the history
There's a mistake in the validation for 
```
var.resource_allocation.cores > var.resource_allocation.vcpus
```

This should in fact be 
```
var.resource_allocation.cores >= var.resource_allocation.vcpus
```

as the config for cores and vcpus can be equals to each other but not
vcpus larger than cores.
  • Loading branch information
hazmei authored Jul 18, 2024
1 parent f8bb1cd commit 9690c9f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ variable "resource_allocation" {
storage = 128
}
validation {
condition = var.resource_allocation.cores > var.resource_allocation.vcpus
condition = var.resource_allocation.cores >= var.resource_allocation.vcpus
error_message = "CPU cores cannot be lesser than VCPUs."
}
validation {
Expand Down

0 comments on commit 9690c9f

Please sign in to comment.