Allow to not use any health check
Internet / serverless NEGs (Cloud Run) don't use them and it's an error to add one in their backend services.
This commit is contained in:
parent
89da766801
commit
08ba94aebc
|
@ -46,7 +46,7 @@ resource "google_compute_region_backend_service" "default" {
|
|||
description = var.description
|
||||
affinity_cookie_ttl_sec = each.value.affinity_cookie_ttl_sec
|
||||
connection_draining_timeout_sec = each.value.connection_draining_timeout_sec
|
||||
health_checks = [
|
||||
health_checks = length(each.value.health_checks) == 0 ? null : [
|
||||
for k in each.value.health_checks : lookup(local.hc_ids, k, k)
|
||||
] # not for internet / serverless NEGs
|
||||
locality_lb_policy = each.value.locality_lb_policy
|
||||
|
|
Loading…
Reference in New Issue