From 7a7f7ed8ac3b02c3ae5699f2c7f31e9513c63c87 Mon Sep 17 00:00:00 2001 From: Diogo Teixeira Date: Thu, 20 Jun 2024 21:01:46 +0100 Subject: [PATCH] Add forward_proxy_uri support --- modules/apigee/README.md | 8 ++++---- modules/apigee/main.tf | 13 +++++++------ modules/apigee/variables.tf | 13 +++++++------ 3 files changed, 18 insertions(+), 16 deletions(-) diff --git a/modules/apigee/README.md b/modules/apigee/README.md index ebae675f31..a4be05599f 100644 --- a/modules/apigee/README.md +++ b/modules/apigee/README.md @@ -359,13 +359,13 @@ module "apigee" { | name | description | type | required | default | |---|---|:---:|:---:|:---:| -| [project_id](variables.tf#L130) | Project ID. | string | ✓ | | +| [project_id](variables.tf#L131) | Project ID. | string | ✓ | | | [addons_config](variables.tf#L17) | Addons configuration. | object({…}) | | null | | [endpoint_attachments](variables.tf#L29) | Endpoint attachments. | map(object({…})) | | {} | | [envgroups](variables.tf#L39) | Environment groups (NAME => [HOSTNAMES]). | map(list(string)) | | {} | -| [environments](variables.tf#L46) | Environments. | map(object({…})) | | {} | -| [instances](variables.tf#L73) | Instances ([REGION] => [INSTANCE]). | map(object({…})) | | {} | -| [organization](variables.tf#L98) | Apigee organization. If set to null the organization must already exist. | object({…}) | | null | +| [environments](variables.tf#L46) | Environments. | map(object({…})) | | {} | +| [instances](variables.tf#L74) | Instances ([REGION] => [INSTANCE]). | map(object({…})) | | {} | +| [organization](variables.tf#L99) | Apigee organization. If set to null the organization must already exist. | object({…}) | | null | ## Outputs diff --git a/modules/apigee/main.tf b/modules/apigee/main.tf index afbc1e5af6..480d19feb5 100644 --- a/modules/apigee/main.tf +++ b/modules/apigee/main.tf @@ -54,12 +54,13 @@ resource "google_apigee_envgroup" "envgroups" { } resource "google_apigee_environment" "environments" { - for_each = var.environments - api_proxy_type = each.value.api_proxy_type - deployment_type = each.value.deployment_type - description = each.value.description - display_name = each.value.display_name - name = each.key + for_each = var.environments + api_proxy_type = each.value.api_proxy_type + deployment_type = each.value.deployment_type + description = each.value.description + display_name = each.value.display_name + forward_proxy_uri = each.value.forward_proxy_uri + name = each.key dynamic "node_config" { for_each = try(each.value.node_config, null) != null ? [""] : [] content { diff --git a/modules/apigee/variables.tf b/modules/apigee/variables.tf index 6ce9fdcf1f..e8d1ffb664 100644 --- a/modules/apigee/variables.tf +++ b/modules/apigee/variables.tf @@ -46,12 +46,13 @@ variable "envgroups" { variable "environments" { description = "Environments." type = map(object({ - api_proxy_type = optional(string) - description = optional(string, "Terraform-managed") - display_name = optional(string) - deployment_type = optional(string) - envgroups = optional(list(string), []) - iam = optional(map(list(string)), {}) + api_proxy_type = optional(string) + description = optional(string, "Terraform-managed") + display_name = optional(string) + deployment_type = optional(string) + envgroups = optional(list(string), []) + forward_proxy_uri = optional(string) + iam = optional(map(list(string)), {}) iam_bindings = optional(map(object({ role = string members = list(string)