Output all neg ids in app lbs (#1879)

Co-authored-by: Ludovico Magnocavallo <ludomagno@google.com>
This commit is contained in:
Julio Castillo 2023-11-23 08:41:31 +01:00 committed by GitHub
parent 642f65b841
commit 7baa1f98d4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 48 additions and 7 deletions

View File

@ -888,8 +888,11 @@ module "glb-0" {
| [backend_service_ids](outputs.tf#L22) | Backend service resources. | |
| [backend_service_names](outputs.tf#L29) | Backend service resource names. | |
| [forwarding_rule](outputs.tf#L36) | Forwarding rule resource. | |
| [group_ids](outputs.tf#L41) | Autogenerated instance group ids. | |
| [health_check_ids](outputs.tf#L48) | Autogenerated health check ids. | |
| [id](outputs.tf#L55) | Fully qualified forwarding rule id. | |
| [neg_ids](outputs.tf#L60) | Autogenerated network endpoint group ids. | |
| [global_neg_ids](outputs.tf#L41) | Autogenerated global network endpoint group ids. | |
| [group_ids](outputs.tf#L48) | Autogenerated instance group ids. | |
| [health_check_ids](outputs.tf#L55) | Autogenerated health check ids. | |
| [id](outputs.tf#L62) | Fully qualified forwarding rule id. | |
| [neg_ids](outputs.tf#L67) | Autogenerated network endpoint group ids. | |
| [psc_neg_ids](outputs.tf#L74) | Autogenerated PSC network endpoint group ids. | |
| [serverless_neg_ids](outputs.tf#L81) | Autogenerated serverless network endpoint group ids. | |
<!-- END TFDOC -->

View File

@ -1,5 +1,5 @@
/**
* Copyright 2022 Google LLC
* Copyright 2023 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -38,6 +38,13 @@ output "forwarding_rule" {
value = google_compute_global_forwarding_rule.default
}
output "global_neg_ids" {
description = "Autogenerated global network endpoint group ids."
value = {
for k, v in google_compute_global_network_endpoint_group.default : k => v.id
}
}
output "group_ids" {
description = "Autogenerated instance group ids."
value = {
@ -63,3 +70,17 @@ output "neg_ids" {
for k, v in google_compute_network_endpoint_group.default : k => v.id
}
}
output "psc_neg_ids" {
description = "Autogenerated PSC network endpoint group ids."
value = {
for k, v in google_compute_region_network_endpoint_group.psc : k => v.id
}
}
output "serverless_neg_ids" {
description = "Autogenerated serverless network endpoint group ids."
value = {
for k, v in google_compute_region_network_endpoint_group.serverless : k => v.id
}
}

View File

@ -687,5 +687,7 @@ module "ilb-l7" {
| [group_ids](outputs.tf#L41) | Autogenerated instance group ids. | |
| [health_check_ids](outputs.tf#L48) | Autogenerated health check ids. | |
| [id](outputs.tf#L55) | Fully qualified forwarding rule id. | |
| [neg_ids](outputs.tf#L60) | Autogenerated network endpoint group ids. | |
| [neg_ids](outputs.tf#L61) | Autogenerated network endpoint group ids. | |
| [psc_neg_ids](outputs.tf#L68) | Autogenerated PSC network endpoint group ids. | |
| [regional_neg_ids](outputs.tf#L75) | Autogenerated regional network endpoint group ids. | |
<!-- END TFDOC -->

View File

@ -1,5 +1,5 @@
/**
* Copyright 2022 Google LLC
* Copyright 2023 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -57,9 +57,24 @@ output "id" {
value = google_compute_forwarding_rule.default.id
}
output "neg_ids" {
description = "Autogenerated network endpoint group ids."
value = {
for k, v in google_compute_network_endpoint_group.default : k => v.id
}
}
output "psc_neg_ids" {
description = "Autogenerated PSC network endpoint group ids."
value = {
for k, v in google_compute_region_network_endpoint_group.psc : k => v.id
}
}
output "regional_neg_ids" {
description = "Autogenerated regional network endpoint group ids."
value = {
for k, v in google_compute_region_network_endpoint_group.default : k => v.id
}
}