Skip to content

Commit

Permalink
fix: remove unnecessary validation block
Browse files Browse the repository at this point in the history
Although supplying incompatible network and subnetworks will not work,
it is not strictly required to supply just one or the other; we should
not introduce this change in behavior in 10.0 on a field that existed in
9.0.
  • Loading branch information
tpdownes committed Sep 8, 2023
1 parent 5c47d1c commit f98c46a
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions modules/instance_template/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -230,12 +230,6 @@ variable "additional_networks" {
subnetwork_range_name = string
}))
}))
validation {
condition = alltrue([
for ni in var.additional_networks : (ni.network == null) != (ni.subnetwork == null)
])
error_message = "All additional network interfaces must define exactly one of \"network\" or \"subnetwork\"."
}
validation {
condition = alltrue([
for ni in var.additional_networks : ni.nic_type == "GVNIC" || ni.nic_type == "VIRTIO_NET" || ni.nic_type == null
Expand Down

0 comments on commit f98c46a

Please sign in to comment.