Fix net vpc firewall module schema (#3099)
* fix ports in net vpc firewall module schema * default ports to []
This commit is contained in:
committed by
GitHub
parent
2e3335630a
commit
2a5e5833a9
@@ -154,7 +154,7 @@ resource "google_compute_firewall" "custom-rules" {
|
||||
iterator = rule
|
||||
content {
|
||||
protocol = rule.value.protocol
|
||||
ports = rule.value.ports
|
||||
ports = try(rule.value.ports, [])
|
||||
}
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ resource "google_compute_firewall" "custom-rules" {
|
||||
iterator = rule
|
||||
content {
|
||||
protocol = rule.value.protocol
|
||||
ports = rule.value.ports
|
||||
ports = try(rule.value.ports, [])
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,7 +88,11 @@
|
||||
"ports": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "number"
|
||||
"type": [
|
||||
"integer",
|
||||
"string"
|
||||
],
|
||||
"pattern": "^[0-9]+(?:-[0-9]+)?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user