Fix variable/output sort check

This commit is contained in:
Julio Castillo
2022-11-18 17:48:16 +01:00
parent f26e8646a9
commit 2e700db8a7
30 changed files with 416 additions and 407 deletions

View File

@@ -29,19 +29,19 @@ module "neg" {
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [endpoints](variables.tf#L42) | List of (instance, port, address) of the NEG. | <code title="list&#40;object&#40;&#123;&#10; instance &#61; string&#10; port &#61; number&#10; ip_address &#61; string&#10;&#125;&#41;&#41;">list&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | ✓ | |
| [name](variables.tf#L22) | NEG name. | <code>string</code> | ✓ | |
| [network](variables.tf#L27) | Name or self link of the VPC used for the NEG. Use the self link for Shared VPC. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L17) | NEG project id. | <code>string</code> | ✓ | |
| [subnetwork](variables.tf#L32) | VPC subnetwork name or self link. | <code>string</code> | ✓ | |
| [zone](variables.tf#L37) | NEG zone. | <code>string</code> | ✓ | |
| [endpoints](variables.tf#L17) | List of (instance, port, address) of the NEG. | <code title="list&#40;object&#40;&#123;&#10; instance &#61; string&#10; port &#61; number&#10; ip_address &#61; string&#10;&#125;&#41;&#41;">list&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | ✓ | |
| [name](variables.tf#L26) | NEG name. | <code>string</code> | ✓ | |
| [network](variables.tf#L31) | Name or self link of the VPC used for the NEG. Use the self link for Shared VPC. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L36) | NEG project id. | <code>string</code> | ✓ | |
| [subnetwork](variables.tf#L41) | VPC subnetwork name or self link. | <code>string</code> | ✓ | |
| [zone](variables.tf#L46) | NEG zone. | <code>string</code> | ✓ | |
## Outputs
| name | description | sensitive |
|---|---|:---:|
| [id](outputs.tf#L17) | Network endpoint group ID. | |
| [self_lnk](outputs.tf#L27) | Network endpoint group self link. | |
| [size](outputs.tf#L22) | Size of the network endpoint group. | |
| [self_lnk](outputs.tf#L22) | Network endpoint group self link. | |
| [size](outputs.tf#L27) | Size of the network endpoint group. | |
<!-- END TFDOC -->

View File

@@ -19,12 +19,12 @@ output "id" {
value = google_compute_network_endpoint_group.group.name
}
output "size" {
description = "Size of the network endpoint group."
value = google_compute_network_endpoint_group.group.size
}
output "self_lnk" {
description = "Network endpoint group self link."
value = google_compute_network_endpoint_group.group.self_link
}
output "size" {
description = "Size of the network endpoint group."
value = google_compute_network_endpoint_group.group.size
}

View File

@@ -14,9 +14,13 @@
* limitations under the License.
*/
variable "project_id" {
description = "NEG project id."
type = string
variable "endpoints" {
description = "List of (instance, port, address) of the NEG."
type = list(object({
instance = string
port = number
ip_address = string
}))
}
variable "name" {
@@ -29,6 +33,11 @@ variable "network" {
type = string
}
variable "project_id" {
description = "NEG project id."
type = string
}
variable "subnetwork" {
description = "VPC subnetwork name or self link."
type = string
@@ -38,12 +47,3 @@ variable "zone" {
description = "NEG zone."
type = string
}
variable "endpoints" {
description = "List of (instance, port, address) of the NEG."
type = list(object({
instance = string
port = number
ip_address = string
}))
}

View File

@@ -141,22 +141,22 @@ module "apigee" {
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [project_id](variables.tf#L17) | Project ID. | <code>string</code> | ✓ | |
| [envgroups](variables.tf#L36) | Environment groups (NAME => [HOSTNAMES]). | <code>map&#40;list&#40;string&#41;&#41;</code> | | <code>null</code> |
| [environments](variables.tf#L42) | Environments. | <code title="map&#40;object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; node_config &#61; optional&#40;object&#40;&#123;&#10; min_node_count &#61; optional&#40;number&#41;&#10; max_node_count &#61; optional&#40;number&#41;&#10; current_aggregate_node_count &#61; number&#10; &#125;&#41;&#41;&#10; iam &#61; optional&#40;map&#40;list&#40;string&#41;&#41;&#41;&#10; envgroups &#61; list&#40;string&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [instances](variables.tf#L58) | Instance. | <code title="map&#40;object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; region &#61; string&#10; environments &#61; list&#40;string&#41;&#10; psa_ip_cidr_range &#61; string&#10; disk_encryption_key &#61; optional&#40;string&#41;&#10; consumer_accept_list &#61; optional&#40;list&#40;string&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [organization](variables.tf#L22) | Apigee organization. If set to null the organization must already exist. | <code title="object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; authorized_network &#61; optional&#40;string&#41;&#10; runtime_type &#61; optional&#40;string, &#34;CLOUD&#34;&#41;&#10; billing_type &#61; optional&#40;string&#41;&#10; database_encryption_key &#61; optional&#40;string&#41;&#10; analytics_region &#61; optional&#40;string, &#34;europe-west1&#34;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [project_id](variables.tf#L68) | Project ID. | <code>string</code> | ✓ | |
| [envgroups](variables.tf#L18) | Environment groups (NAME => [HOSTNAMES]). | <code>map&#40;list&#40;string&#41;&#41;</code> | | <code>null</code> |
| [environments](variables.tf#L24) | Environments. | <code title="map&#40;object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; node_config &#61; optional&#40;object&#40;&#123;&#10; min_node_count &#61; optional&#40;number&#41;&#10; max_node_count &#61; optional&#40;number&#41;&#10; current_aggregate_node_count &#61; number&#10; &#125;&#41;&#41;&#10; iam &#61; optional&#40;map&#40;list&#40;string&#41;&#41;&#41;&#10; envgroups &#61; list&#40;string&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [instances](variables.tf#L40) | Instance. | <code title="map&#40;object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; region &#61; string&#10; environments &#61; list&#40;string&#41;&#10; psa_ip_cidr_range &#61; string&#10; disk_encryption_key &#61; optional&#40;string&#41;&#10; consumer_accept_list &#61; optional&#40;list&#40;string&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [organization](variables.tf#L54) | Apigee organization. If set to null the organization must already exist. | <code title="object&#40;&#123;&#10; display_name &#61; optional&#40;string&#41;&#10; description &#61; optional&#40;string, &#34;Terraform-managed&#34;&#41;&#10; authorized_network &#61; optional&#40;string&#41;&#10; runtime_type &#61; optional&#40;string, &#34;CLOUD&#34;&#41;&#10; billing_type &#61; optional&#40;string&#41;&#10; database_encryption_key &#61; optional&#40;string&#41;&#10; analytics_region &#61; optional&#40;string, &#34;europe-west1&#34;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
## Outputs
| name | description | sensitive |
|---|---|:---:|
| [envgroups](outputs.tf#L32) | Environment groups. | |
| [environments](outputs.tf#L37) | Environment. | |
| [instances](outputs.tf#L42) | Instances | |
| [org_id](outputs.tf#L22) | Organization ID. | |
| [org_name](outputs.tf#L27) | Organization name. | |
| [organization](outputs.tf#L17) | Organization. | |
| [envgroups](outputs.tf#L17) | Environment groups. | |
| [environments](outputs.tf#L22) | Environment. | |
| [instances](outputs.tf#L27) | Instances | |
| [org_id](outputs.tf#L32) | Organization ID. | |
| [org_name](outputs.tf#L37) | Organization name. | |
| [organization](outputs.tf#L42) | Organization. | |
| [service_attachments](outputs.tf#L47) | Service attachments. | |
<!-- END TFDOC -->

View File

@@ -14,21 +14,6 @@
* limitations under the License.
*/
output "organization" {
description = "Organization."
value = try(google_apigee_organization.organization[0], null)
}
output "org_id" {
description = "Organization ID."
value = local.org_id
}
output "org_name" {
description = "Organization name."
value = try(google_apigee_organization.organization[0].name, var.project_id)
}
output "envgroups" {
description = "Environment groups."
value = try(google_apigee_envgroup.envgroups, null)
@@ -44,6 +29,21 @@ output "instances" {
value = try(google_apigee_instance.instances, null)
}
output "org_id" {
description = "Organization ID."
value = local.org_id
}
output "org_name" {
description = "Organization name."
value = try(google_apigee_organization.organization[0].name, var.project_id)
}
output "organization" {
description = "Organization."
value = try(google_apigee_organization.organization[0], null)
}
output "service_attachments" {
description = "Service attachments."
value = { for k, v in google_apigee_instance.instances : k => v.service_attachment }

View File

@@ -14,24 +14,6 @@
* limitations under the License.
*/
variable "project_id" {
description = "Project ID."
type = string
}
variable "organization" {
description = "Apigee organization. If set to null the organization must already exist."
type = object({
display_name = optional(string)
description = optional(string, "Terraform-managed")
authorized_network = optional(string)
runtime_type = optional(string, "CLOUD")
billing_type = optional(string)
database_encryption_key = optional(string)
analytics_region = optional(string, "europe-west1")
})
default = null
}
variable "envgroups" {
description = "Environment groups (NAME => [HOSTNAMES])."
@@ -68,3 +50,22 @@ variable "instances" {
}))
default = null
}
variable "organization" {
description = "Apigee organization. If set to null the organization must already exist."
type = object({
display_name = optional(string)
description = optional(string, "Terraform-managed")
authorized_network = optional(string)
runtime_type = optional(string, "CLOUD")
billing_type = optional(string)
database_encryption_key = optional(string)
analytics_region = optional(string, "europe-west1")
})
default = null
}
variable "project_id" {
description = "Project ID."
type = string
}

View File

@@ -61,19 +61,19 @@ module "binauthz" {
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [project_id](variables.tf#L17) | Project ID. | <code>string</code> | ✓ | |
| [admission_whitelist_patterns](variables.tf#L28) | An image name pattern to allowlist | <code>list&#40;string&#41;</code> | | <code>null</code> |
| [attestors_config](variables.tf#L58) | Attestors configuration | <code title="map&#40;object&#40;&#123;&#10; note_reference &#61; string&#10; iam &#61; map&#40;list&#40;string&#41;&#41;&#10; pgp_public_keys &#61; list&#40;string&#41;&#10; pkix_public_keys &#61; list&#40;object&#40;&#123;&#10; id &#61; string&#10; public_key_pem &#61; string&#10; signature_algorithm &#61; string&#10; &#125;&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [cluster_admission_rules](variables.tf#L48) | Admission rules | <code title="map&#40;object&#40;&#123;&#10; evaluation_mode &#61; string&#10; enforcement_mode &#61; string&#10; attestors &#61; list&#40;string&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [default_admission_rule](variables.tf#L34) | Default admission rule | <code title="object&#40;&#123;&#10; evaluation_mode &#61; string&#10; enforcement_mode &#61; string&#10; attestors &#61; list&#40;string&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; evaluation_mode &#61; &#34;ALWAYS_ALLOW&#34;&#10; enforcement_mode &#61; &#34;ENFORCED_BLOCK_AND_AUDIT_LOG&#34;&#10; attestors &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [global_policy_evaluation_mode](variables.tf#L22) | Global policy evaluation mode. | <code>string</code> | | <code>null</code> |
| [project_id](variables.tf#L68) | Project ID. | <code>string</code> | ✓ | |
| [admission_whitelist_patterns](variables.tf#L17) | An image name pattern to allowlist | <code>list&#40;string&#41;</code> | | <code>null</code> |
| [attestors_config](variables.tf#L23) | Attestors configuration | <code title="map&#40;object&#40;&#123;&#10; note_reference &#61; string&#10; iam &#61; map&#40;list&#40;string&#41;&#41;&#10; pgp_public_keys &#61; list&#40;string&#41;&#10; pkix_public_keys &#61; list&#40;object&#40;&#123;&#10; id &#61; string&#10; public_key_pem &#61; string&#10; signature_algorithm &#61; string&#10; &#125;&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [cluster_admission_rules](variables.tf#L38) | Admission rules | <code title="map&#40;object&#40;&#123;&#10; evaluation_mode &#61; string&#10; enforcement_mode &#61; string&#10; attestors &#61; list&#40;string&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>null</code> |
| [default_admission_rule](variables.tf#L48) | Default admission rule | <code title="object&#40;&#123;&#10; evaluation_mode &#61; string&#10; enforcement_mode &#61; string&#10; attestors &#61; list&#40;string&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; evaluation_mode &#61; &#34;ALWAYS_ALLOW&#34;&#10; enforcement_mode &#61; &#34;ENFORCED_BLOCK_AND_AUDIT_LOG&#34;&#10; attestors &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [global_policy_evaluation_mode](variables.tf#L62) | Global policy evaluation mode. | <code>string</code> | | <code>null</code> |
## Outputs
| name | description | sensitive |
|---|---|:---:|
| [attestors](outputs.tf#L22) | Attestors. | |
| [id](outputs.tf#L17) | Binary Authorization policy ID | |
| [attestors](outputs.tf#L17) | Attestors. | |
| [id](outputs.tf#L25) | Binary Authorization policy ID | |
| [notes](outputs.tf#L30) | Notes. | |
<!-- END TFDOC -->

View File

@@ -14,11 +14,6 @@
* limitations under the License.
*/
output "id" {
description = "Binary Authorization policy ID"
value = google_binary_authorization_policy.policy.id
}
output "attestors" {
description = "Attestors."
value = google_binary_authorization_attestor.attestors
@@ -27,6 +22,11 @@ output "attestors" {
]
}
output "id" {
description = "Binary Authorization policy ID"
value = google_binary_authorization_policy.policy.id
}
output "notes" {
description = "Notes."
value = google_container_analysis_note.notes

View File

@@ -14,47 +14,12 @@
* limitations under the License.
*/
variable "project_id" {
description = "Project ID."
type = string
}
variable "global_policy_evaluation_mode" {
description = "Global policy evaluation mode."
type = string
default = null
}
variable "admission_whitelist_patterns" {
description = "An image name pattern to allowlist"
type = list(string)
default = null
}
variable "default_admission_rule" {
description = "Default admission rule"
type = object({
evaluation_mode = string
enforcement_mode = string
attestors = list(string)
})
default = {
evaluation_mode = "ALWAYS_ALLOW"
enforcement_mode = "ENFORCED_BLOCK_AND_AUDIT_LOG"
attestors = null
}
}
variable "cluster_admission_rules" {
description = "Admission rules"
type = map(object({
evaluation_mode = string
enforcement_mode = string
attestors = list(string)
}))
default = null
}
variable "attestors_config" {
description = "Attestors configuration"
type = map(object({
@@ -69,3 +34,38 @@ variable "attestors_config" {
}))
default = null
}
variable "cluster_admission_rules" {
description = "Admission rules"
type = map(object({
evaluation_mode = string
enforcement_mode = string
attestors = list(string)
}))
default = null
}
variable "default_admission_rule" {
description = "Default admission rule"
type = object({
evaluation_mode = string
enforcement_mode = string
attestors = list(string)
})
default = {
evaluation_mode = "ALWAYS_ALLOW"
enforcement_mode = "ENFORCED_BLOCK_AND_AUDIT_LOG"
attestors = null
}
}
variable "global_policy_evaluation_mode" {
description = "Global policy evaluation mode."
type = string
default = null
}
variable "project_id" {
description = "Project ID."
type = string
}

View File

@@ -14,6 +14,19 @@
* limitations under the License.
*/
variable "allow" {
description = "List of domains Squid will allow connections to."
type = list(string)
default = []
}
variable "clients" {
description = "List of CIDR ranges from which Squid will allow connections."
type = list(string)
default = []
}
variable "cloud_config" {
description = "Cloud config template path. If null default will be used."
type = string
@@ -26,10 +39,30 @@ variable "config_variables" {
default = {}
}
variable "squid_config" {
description = "Squid configuration path, if null default will be used."
variable "default_action" {
description = "Default action for domains not matching neither the allow or deny lists."
type = string
default = null
default = "deny"
validation {
condition = var.default_action == "deny" || var.default_action == "allow"
error_message = "Default action must be allow or deny."
}
}
variable "deny" {
description = "List of domains Squid will deny connections to."
type = list(string)
default = []
}
variable "files" {
description = "Map of extra files to create on the instance, path as key. Owner and permissions will use defaults if null."
type = map(object({
content = string
owner = string
permissions = string
}))
default = {}
}
variable "file_defaults" {
@@ -44,40 +77,8 @@ variable "file_defaults" {
}
}
variable "files" {
description = "Map of extra files to create on the instance, path as key. Owner and permissions will use defaults if null."
type = map(object({
content = string
owner = string
permissions = string
}))
default = {}
}
variable "allow" {
description = "List of domains Squid will allow connections to."
type = list(string)
default = []
}
variable "deny" {
description = "List of domains Squid will deny connections to."
type = list(string)
default = []
}
variable "clients" {
description = "List of CIDR ranges from which Squid will allow connections."
type = list(string)
default = []
}
variable "default_action" {
description = "Default action for domains not matching neither the allow or deny lists."
variable "squid_config" {
description = "Squid configuration path, if null default will be used."
type = string
default = "deny"
validation {
condition = var.default_action == "deny" || var.default_action == "allow"
error_message = "Default action must be allow or deny."
}
default = null
}

View File

@@ -243,9 +243,9 @@ module "cf-http" {
| [service_account](variables.tf#L132) | Service account email. Unused if service account is auto-created. | <code>string</code> | | <code>null</code> |
| [service_account_create](variables.tf#L138) | Auto-create service account. | <code>bool</code> | | <code>false</code> |
| [trigger_config](variables.tf#L144) | Function trigger configuration. Leave null for HTTP trigger. | <code title="object&#40;&#123;&#10; v1 &#61; optional&#40;object&#40;&#123;&#10; event &#61; string&#10; resource &#61; string&#10; retry &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;,&#10; v2 &#61; optional&#40;object&#40;&#123;&#10; region &#61; optional&#40;string&#41;&#10; event_type &#61; optional&#40;string&#41;&#10; pubsub_topic &#61; optional&#40;string&#41;&#10; event_filters &#61; optional&#40;list&#40;object&#40;&#123;&#10; attribute &#61; string&#10; value &#61; string&#10; operator &#61; string&#10; &#125;&#41;&#41;&#41;&#10; service_account_email &#61; optional&#40;string&#41;&#10; service_account_create &#61; optional&#40;bool&#41;&#10; retry_policy &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>&#123; v1 &#61; null, v2 &#61; null &#125;</code> |
| [v2](variables.tf#L192) | Whether to use Cloud Function version 2nd Gen or 1st Gen. | <code>bool</code> | | <code>false</code> |
| [vpc_connector](variables.tf#L173) | VPC connector configuration. Set create to 'true' if a new connector needs to be created. | <code title="object&#40;&#123;&#10; create &#61; bool&#10; name &#61; string&#10; egress_settings &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [vpc_connector_config](variables.tf#L183) | VPC connector network configuration. Must be provided if new VPC connector is being created. | <code title="object&#40;&#123;&#10; ip_cidr_range &#61; string&#10; network &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [v2](variables.tf#L173) | Whether to use Cloud Function version 2nd Gen or 1st Gen. | <code>bool</code> | | <code>false</code> |
| [vpc_connector](variables.tf#L179) | VPC connector configuration. Set create to 'true' if a new connector needs to be created. | <code title="object&#40;&#123;&#10; create &#61; bool&#10; name &#61; string&#10; egress_settings &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [vpc_connector_config](variables.tf#L189) | VPC connector network configuration. Must be provided if new VPC connector is being created. | <code title="object&#40;&#123;&#10; ip_cidr_range &#61; string&#10; network &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
## Outputs
@@ -255,13 +255,13 @@ module "cf-http" {
| [bucket_name](outputs.tf#L24) | Bucket name. | |
| [function](outputs.tf#L29) | Cloud function resources. | |
| [function_name](outputs.tf#L34) | Cloud function name. | |
| [service_account](outputs.tf#L42) | Service account resource. | |
| [service_account_email](outputs.tf#L47) | Service account email. | |
| [service_account_iam_email](outputs.tf#L52) | Service account email. | |
| [trigger_service_account](outputs.tf#L60) | Service account resource. | |
| [trigger_service_account_email](outputs.tf#L65) | Service account email. | |
| [trigger_service_account_iam_email](outputs.tf#L70) | Service account email. | |
| [uri](outputs.tf#L38) | Cloud function service uri. | |
| [vpc_connector](outputs.tf#L78) | VPC connector resource if created. | |
| [service_account](outputs.tf#L39) | Service account resource. | |
| [service_account_email](outputs.tf#L44) | Service account email. | |
| [service_account_iam_email](outputs.tf#L49) | Service account email. | |
| [trigger_service_account](outputs.tf#L57) | Service account resource. | |
| [trigger_service_account_email](outputs.tf#L62) | Service account email. | |
| [trigger_service_account_iam_email](outputs.tf#L67) | Service account email. | |
| [uri](outputs.tf#L75) | Cloud function service uri. | |
| [vpc_connector](outputs.tf#L80) | VPC connector resource if created. | |
<!-- END TFDOC -->

View File

@@ -35,10 +35,7 @@ output "function_name" {
description = "Cloud function name."
value = local.function.name
}
output "uri" {
description = "Cloud function service uri."
value = var.v2 ? google_cloudfunctions2_function.function[0].service_config[0].uri : null
}
output "service_account" {
description = "Service account resource."
value = try(google_service_account.service_account[0], null)
@@ -75,6 +72,11 @@ output "trigger_service_account_iam_email" {
])
}
output "uri" {
description = "Cloud function service uri."
value = var.v2 ? google_cloudfunctions2_function.function[0].service_config[0].uri : null
}
output "vpc_connector" {
description = "VPC connector resource if created."
value = try(google_vpc_access_connector.connector.0.id, null)

View File

@@ -170,6 +170,12 @@ variable "trigger_config" {
}
}
variable "v2" {
description = "Whether to use Cloud Function version 2nd Gen or 1st Gen."
type = bool
default = false
}
variable "vpc_connector" {
description = "VPC connector configuration. Set create to 'true' if a new connector needs to be created."
type = object({
@@ -189,10 +195,4 @@ variable "vpc_connector_config" {
default = null
}
variable "v2" {
description = "Whether to use Cloud Function version 2nd Gen or 1st Gen."
type = bool
default = false
}

View File

@@ -146,27 +146,27 @@ module "db" {
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [database_version](variables.tf#L50) | Database type and version to create. | <code>string</code> | ✓ | |
| [name](variables.tf#L97) | Name of primary instance. | <code>string</code> | ✓ | |
| [network](variables.tf#L102) | VPC self link where the instances will be deployed. Private Service Networking must be enabled and configured in this VPC. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L117) | The ID of the project where this instances will be created. | <code>string</code> | ✓ | |
| [region](variables.tf#L122) | Region of the primary instance. | <code>string</code> | ✓ | |
| [tier](variables.tf#L142) | The machine type to use for the instances. | <code>string</code> | ✓ | |
| [database_version](variables.tf#L49) | Database type and version to create. | <code>string</code> | ✓ | |
| [name](variables.tf#L102) | Name of primary instance. | <code>string</code> | ✓ | |
| [network](variables.tf#L107) | VPC self link where the instances will be deployed. Private Service Networking must be enabled and configured in this VPC. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L122) | The ID of the project where this instances will be created. | <code>string</code> | ✓ | |
| [region](variables.tf#L127) | Region of the primary instance. | <code>string</code> | ✓ | |
| [tier](variables.tf#L147) | The machine type to use for the instances. | <code>string</code> | ✓ | |
| [authorized_networks](variables.tf#L17) | Map of NAME=>CIDR_RANGE to allow to connect to the database(s). | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [availability_type](variables.tf#L23) | Availability type for the primary replica. Either `ZONAL` or `REGIONAL`. | <code>string</code> | | <code>&#34;ZONAL&#34;</code> |
| [backup_configuration](variables.tf#L29) | Backup settings for primary instance. Will be automatically enabled if using MySQL with one or more replicas. | <code title="object&#40;&#123;&#10; enabled &#61; bool&#10; binary_log_enabled &#61; bool&#10; start_time &#61; string&#10; location &#61; string&#10; log_retention_days &#61; number&#10; retention_count &#61; number&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; enabled &#61; false&#10; binary_log_enabled &#61; false&#10; start_time &#61; &#34;23:00&#34;&#10; location &#61; null&#10; log_retention_days &#61; 7&#10; retention_count &#61; 7&#10;&#125;">&#123;&#8230;&#125;</code> |
| [databases](variables.tf#L55) | Databases to create once the primary instance is created. | <code>list&#40;string&#41;</code> | | <code>null</code> |
| [deletion_protection](variables.tf#L61) | Allow terraform to delete instances. | <code>bool</code> | | <code>false</code> |
| [disk_size](variables.tf#L67) | Disk size in GB. Set to null to enable autoresize. | <code>number</code> | | <code>null</code> |
| [disk_type](variables.tf#L73) | The type of data disk: `PD_SSD` or `PD_HDD`. | <code>string</code> | | <code>&#34;PD_SSD&#34;</code> |
| [encryption_key_name](variables.tf#L79) | The full path to the encryption key used for the CMEK disk encryption of the primary instance. | <code>string</code> | | <code>null</code> |
| [flags](variables.tf#L85) | Map FLAG_NAME=>VALUE for database-specific tuning. | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [ipv4_enabled](variables.tf#L153) | Add a public IP address to database instance. | <code>bool</code> | | <code>false</code> |
| [labels](variables.tf#L91) | Labels to be attached to all instances. | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [prefix](variables.tf#L107) | Optional prefix used to generate instance names. | <code>string</code> | | <code>null</code> |
| [replicas](variables.tf#L127) | Map of NAME=> {REGION, KMS_KEY} for additional read replicas. Set to null to disable replica creation. | <code title="map&#40;object&#40;&#123;&#10; region &#61; string&#10; encryption_key_name &#61; string&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [root_password](variables.tf#L136) | Root password of the Cloud SQL instance. Required for MS SQL Server | <code>string</code> | | <code>null</code> |
| [users](variables.tf#L147) | Map of users to create in the primary instance (and replicated to other replicas) in the format USER=>PASSWORD. For MySQL, anything afterr the first `@` (if persent) will be used as the user's host. Set PASSWORD to null if you want to get an autogenerated password. | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [databases](variables.tf#L54) | Databases to create once the primary instance is created. | <code>list&#40;string&#41;</code> | | <code>null</code> |
| [deletion_protection](variables.tf#L60) | Allow terraform to delete instances. | <code>bool</code> | | <code>false</code> |
| [disk_size](variables.tf#L66) | Disk size in GB. Set to null to enable autoresize. | <code>number</code> | | <code>null</code> |
| [disk_type](variables.tf#L72) | The type of data disk: `PD_SSD` or `PD_HDD`. | <code>string</code> | | <code>&#34;PD_SSD&#34;</code> |
| [encryption_key_name](variables.tf#L78) | The full path to the encryption key used for the CMEK disk encryption of the primary instance. | <code>string</code> | | <code>null</code> |
| [flags](variables.tf#L84) | Map FLAG_NAME=>VALUE for database-specific tuning. | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [ipv4_enabled](variables.tf#L90) | Add a public IP address to database instance. | <code>bool</code> | | <code>false</code> |
| [labels](variables.tf#L96) | Labels to be attached to all instances. | <code>map&#40;string&#41;</code> | | <code>null</code> |
| [prefix](variables.tf#L112) | Optional prefix used to generate instance names. | <code>string</code> | | <code>null</code> |
| [replicas](variables.tf#L132) | Map of NAME=> {REGION, KMS_KEY} for additional read replicas. Set to null to disable replica creation. | <code title="map&#40;object&#40;&#123;&#10; region &#61; string&#10; encryption_key_name &#61; string&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [root_password](variables.tf#L141) | Root password of the Cloud SQL instance. Required for MS SQL Server | <code>string</code> | | <code>null</code> |
| [users](variables.tf#L152) | Map of users to create in the primary instance (and replicated to other replicas) in the format USER=>PASSWORD. For MySQL, anything afterr the first `@` (if persent) will be used as the user's host. Set PASSWORD to null if you want to get an autogenerated password. | <code>map&#40;string&#41;</code> | | <code>null</code> |
## Outputs

View File

@@ -46,7 +46,6 @@ variable "backup_configuration" {
}
}
variable "database_version" {
description = "Database type and version to create."
type = string
@@ -88,6 +87,12 @@ variable "flags" {
default = null
}
variable "ipv4_enabled" {
description = "Add a public IP address to database instance."
type = bool
default = false
}
variable "labels" {
description = "Labels to be attached to all instances."
type = map(string)
@@ -149,9 +154,3 @@ variable "users" {
type = map(string)
default = null
}
variable "ipv4_enabled" {
description = "Add a public IP address to database instance."
type = bool
default = false
}

View File

@@ -429,8 +429,8 @@ module "nginx-mig" {
| [distribution_policy](variables.tf#L95) | DIstribution policy for regional MIG. | <code title="object&#40;&#123;&#10; target_shape &#61; optional&#40;string&#41;&#10; zones &#61; optional&#40;list&#40;string&#41;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [health_check_config](variables.tf#L104) | Optional auto-created health check configuration, use the output self-link to set it in the auto healing policy. Refer to examples for usage. | <code title="object&#40;&#123;&#10; check_interval_sec &#61; optional&#40;number&#41;&#10; description &#61; optional&#40;string, &#34;Terraform managed.&#34;&#41;&#10; enable_logging &#61; optional&#40;bool, false&#41;&#10; healthy_threshold &#61; optional&#40;number&#41;&#10; timeout_sec &#61; optional&#40;number&#41;&#10; unhealthy_threshold &#61; optional&#40;number&#41;&#10; grpc &#61; optional&#40;object&#40;&#123;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; service_name &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10; http &#61; optional&#40;object&#40;&#123;&#10; host &#61; optional&#40;string&#41;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; proxy_header &#61; optional&#40;string&#41;&#10; request_path &#61; optional&#40;string&#41;&#10; response &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10; http2 &#61; optional&#40;object&#40;&#123;&#10; host &#61; optional&#40;string&#41;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; proxy_header &#61; optional&#40;string&#41;&#10; request_path &#61; optional&#40;string&#41;&#10; response &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10; https &#61; optional&#40;object&#40;&#123;&#10; host &#61; optional&#40;string&#41;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; proxy_header &#61; optional&#40;string&#41;&#10; request_path &#61; optional&#40;string&#41;&#10; response &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10; tcp &#61; optional&#40;object&#40;&#123;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; proxy_header &#61; optional&#40;string&#41;&#10; request &#61; optional&#40;string&#41;&#10; response &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10; ssl &#61; optional&#40;object&#40;&#123;&#10; port &#61; optional&#40;number&#41;&#10; port_name &#61; optional&#40;string&#41;&#10; port_specification &#61; optional&#40;string&#41; &#35; USE_FIXED_PORT USE_NAMED_PORT USE_SERVING_PORT&#10; proxy_header &#61; optional&#40;string&#41;&#10; request &#61; optional&#40;string&#41;&#10; response &#61; optional&#40;string&#41;&#10; &#125;&#41;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [named_ports](variables.tf#L189) | Named ports. | <code>map&#40;number&#41;</code> | | <code>null</code> |
| [stateful_config](variables.tf#L207) | Stateful configuration for individual instances. | <code title="map&#40;object&#40;&#123;&#10; minimal_action &#61; optional&#40;string&#41;&#10; most_disruptive_action &#61; optional&#40;string&#41;&#10; remove_state_on_destroy &#61; optional&#40;bool&#41;&#10; preserved_state &#61; optional&#40;object&#40;&#123;&#10; disks &#61; optional&#40;map&#40;object&#40;&#123;&#10; source &#61; string&#10; delete_on_instance_deletion &#61; optional&#40;bool&#41;&#10; read_only &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;&#41;&#10; metadata &#61; optional&#40;map&#40;string&#41;&#41;&#10; &#125;&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [stateful_disks](variables.tf#L200) | Stateful disk configuration applied at the MIG level to all instances, in device name => on permanent instance delete rule as boolean. | <code>map&#40;bool&#41;</code> | | <code>&#123;&#125;</code> |
| [stateful_config](variables.tf#L200) | Stateful configuration for individual instances. | <code title="map&#40;object&#40;&#123;&#10; minimal_action &#61; optional&#40;string&#41;&#10; most_disruptive_action &#61; optional&#40;string&#41;&#10; remove_state_on_destroy &#61; optional&#40;bool&#41;&#10; preserved_state &#61; optional&#40;object&#40;&#123;&#10; disks &#61; optional&#40;map&#40;object&#40;&#123;&#10; source &#61; string&#10; delete_on_instance_deletion &#61; optional&#40;bool&#41;&#10; read_only &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;&#41;&#10; metadata &#61; optional&#40;map&#40;string&#41;&#41;&#10; &#125;&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [stateful_disks](variables.tf#L219) | Stateful disk configuration applied at the MIG level to all instances, in device name => on permanent instance delete rule as boolean. | <code>map&#40;bool&#41;</code> | | <code>&#123;&#125;</code> |
| [target_pools](variables.tf#L226) | Optional list of URLs for target pools to which new instances in the group are added. | <code>list&#40;string&#41;</code> | | <code>&#91;&#93;</code> |
| [target_size](variables.tf#L232) | Group target size, leave null when using an autoscaler. | <code>number</code> | | <code>null</code> |
| [update_policy](variables.tf#L238) | Update policy. Minimal action and type are required. | <code title="object&#40;&#123;&#10; minimal_action &#61; string&#10; type &#61; string&#10; max_surge &#61; optional&#40;object&#40;&#123;&#10; fixed &#61; optional&#40;number&#41;&#10; percent &#61; optional&#40;number&#41;&#10; &#125;&#41;&#41;&#10; max_unavailable &#61; optional&#40;object&#40;&#123;&#10; fixed &#61; optional&#40;number&#41;&#10; percent &#61; optional&#40;number&#41;&#10; &#125;&#41;&#41;&#10; min_ready_sec &#61; optional&#40;number&#41;&#10; most_disruptive_action &#61; optional&#40;string&#41;&#10; regional_redistribution_type &#61; optional&#40;string&#41;&#10; replacement_method &#61; optional&#40;string&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |

View File

@@ -197,13 +197,6 @@ variable "project_id" {
type = string
}
variable "stateful_disks" {
description = "Stateful disk configuration applied at the MIG level to all instances, in device name => on permanent instance delete rule as boolean."
type = map(bool)
default = {}
nullable = false
}
variable "stateful_config" {
description = "Stateful configuration for individual instances."
type = map(object({
@@ -223,6 +216,13 @@ variable "stateful_config" {
nullable = false
}
variable "stateful_disks" {
description = "Stateful disk configuration applied at the MIG level to all instances, in device name => on permanent instance delete rule as boolean."
type = map(bool)
default = {}
nullable = false
}
variable "target_pools" {
description = "Optional list of URLs for target pools to which new instances in the group are added."
type = list(string)

View File

@@ -98,8 +98,8 @@ module "private-dns" {
| [client_networks](variables.tf#L21) | List of VPC self links that can see this zone. | <code>list&#40;string&#41;</code> | | <code>&#91;&#93;</code> |
| [description](variables.tf#L28) | Domain description. | <code>string</code> | | <code>&#34;Terraform managed.&#34;</code> |
| [dnssec_config](variables.tf#L34) | DNSSEC configuration for this zone. | <code title="object&#40;&#123;&#10; non_existence &#61; optional&#40;string, &#34;nsec3&#34;&#41;&#10; state &#61; string&#10; key_signing_key &#61; optional&#40;object&#40;&#10; &#123; algorithm &#61; string, key_length &#61; number &#125;&#41;,&#10; &#123; algorithm &#61; &#34;rsasha256&#34;, key_length &#61; 2048 &#125;&#10; &#41;&#10; zone_signing_key &#61; optional&#40;object&#40;&#10; &#123; algorithm &#61; string, key_length &#61; number &#125;&#41;,&#10; &#123; algorithm &#61; &#34;rsasha256&#34;, key_length &#61; 1024 &#125;&#10; &#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; state &#61; &#34;off&#34;&#10;&#125;">&#123;&#8230;&#125;</code> |
| [enable_logging](variables.tf#L65) | Enable query logging for this zone. Only valid for public zones. | <code>bool</code> | | <code>false</code> |
| [forwarders](variables.tf#L59) | Map of {IPV4_ADDRESS => FORWARDING_PATH} for 'forwarding' zone types. Path can be 'default', 'private', or null for provider default. | <code>map&#40;string&#41;</code> | | <code>&#123;&#125;</code> |
| [enable_logging](variables.tf#L59) | Enable query logging for this zone. Only valid for public zones. | <code>bool</code> | | <code>false</code> |
| [forwarders](variables.tf#L66) | Map of {IPV4_ADDRESS => FORWARDING_PATH} for 'forwarding' zone types. Path can be 'default', 'private', or null for provider default. | <code>map&#40;string&#41;</code> | | <code>&#123;&#125;</code> |
| [peer_network](variables.tf#L77) | Peering network self link, only valid for 'peering' zone types. | <code>string</code> | | <code>null</code> |
| [recordsets](variables.tf#L88) | Map of DNS recordsets in \"type name\" => {ttl, [records]} format. | <code title="map&#40;object&#40;&#123;&#10; ttl &#61; optional&#40;number, 300&#41;&#10; records &#61; optional&#40;list&#40;string&#41;&#41;&#10; geo_routing &#61; optional&#40;list&#40;object&#40;&#123;&#10; location &#61; string&#10; records &#61; list&#40;string&#41;&#10; &#125;&#41;&#41;&#41;&#10; wrr_routing &#61; optional&#40;list&#40;object&#40;&#123;&#10; weight &#61; number&#10; records &#61; list&#40;string&#41;&#10; &#125;&#41;&#41;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [service_directory_namespace](variables.tf#L123) | Service directory namespace id (URL), only valid for 'service-directory' zone types. | <code>string</code> | | <code>null</code> |

View File

@@ -56,12 +56,6 @@ variable "domain" {
type = string
}
variable "forwarders" {
description = "Map of {IPV4_ADDRESS => FORWARDING_PATH} for 'forwarding' zone types. Path can be 'default', 'private', or null for provider default."
type = map(string)
default = {}
}
variable "enable_logging" {
description = "Enable query logging for this zone. Only valid for public zones."
type = bool
@@ -69,6 +63,12 @@ variable "enable_logging" {
nullable = false
}
variable "forwarders" {
description = "Map of {IPV4_ADDRESS => FORWARDING_PATH} for 'forwarding' zone types. Path can be 'default', 'private', or null for provider default."
type = map(string)
default = {}
}
variable "name" {
description = "Zone name, must be unique within the project."
type = string

View File

@@ -549,33 +549,33 @@ Target proxies leverage [url-maps](url-map.tf): set of L7 rules, which create a
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [name](variables.tf#L17) | Load balancer name. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L22) | Project id. | <code>string</code> | ✓ | |
| [backend_services_config](variables.tf#L62) | The backends services configuration. | <code title="map&#40;object&#40;&#123;&#10; enable_cdn &#61; bool&#10;&#10;&#10; cdn_config &#61; object&#40;&#123;&#10; cache_mode &#61; string&#10; client_ttl &#61; number&#10; default_ttl &#61; number&#10; max_ttl &#61; number&#10; negative_caching &#61; bool&#10; negative_caching_policy &#61; map&#40;number&#41;&#10; serve_while_stale &#61; bool&#10; signed_url_cache_max_age_sec &#61; string&#10; &#125;&#41;&#10;&#10;&#10; bucket_config &#61; object&#40;&#123;&#10; bucket_name &#61; string&#10; options &#61; object&#40;&#123;&#10; custom_response_headers &#61; list&#40;string&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#10;&#10; group_config &#61; object&#40;&#123;&#10; backends &#61; list&#40;object&#40;&#123;&#10; group &#61; string &#35; IG or NEG FQDN address&#10; options &#61; object&#40;&#123;&#10; balancing_mode &#61; string &#35; Can be UTILIZATION, RATE, CONNECTION&#10; capacity_scaler &#61; number &#35; Valid range is &#91;0.0,1.0&#93;&#10; max_connections &#61; number&#10; max_connections_per_instance &#61; number&#10; max_connections_per_endpoint &#61; number&#10; max_rate &#61; number&#10; max_rate_per_instance &#61; number&#10; max_rate_per_endpoint &#61; number&#10; max_utilization &#61; number&#10; &#125;&#41;&#10; &#125;&#41;&#41;&#10; health_checks &#61; list&#40;string&#41;&#10;&#10;&#10; log_config &#61; object&#40;&#123;&#10; enable &#61; bool&#10; sample_rate &#61; number &#35; must be in &#91;0, 1&#93;&#10; &#125;&#41;&#10;&#10;&#10; options &#61; object&#40;&#123;&#10; affinity_cookie_ttl_sec &#61; number&#10; custom_request_headers &#61; list&#40;string&#41;&#10; custom_response_headers &#61; list&#40;string&#41;&#10; connection_draining_timeout_sec &#61; number&#10; load_balancing_scheme &#61; string &#35; only EXTERNAL &#40;default&#41; makes sense here&#10; locality_lb_policy &#61; string&#10; port_name &#61; string&#10; protocol &#61; string&#10; security_policy &#61; string&#10; session_affinity &#61; string&#10; timeout_sec &#61; number&#10;&#10;&#10; circuits_breakers &#61; object&#40;&#123;&#10; max_requests_per_connection &#61; number &#35; Set to 1 to disable keep-alive&#10; max_connections &#61; number &#35; Defaults to 1024&#10; max_pending_requests &#61; number &#35; Defaults to 1024&#10; max_requests &#61; number &#35; Defaults to 1024&#10; max_retries &#61; number &#35; Defaults to 3&#10; &#125;&#41;&#10;&#10;&#10; consistent_hash &#61; object&#40;&#123;&#10; http_header_name &#61; string&#10; minimum_ring_size &#61; string&#10; http_cookie &#61; object&#40;&#123;&#10; name &#61; string&#10; path &#61; string&#10; ttl &#61; object&#40;&#123;&#10; seconds &#61; number&#10; nanos &#61; number&#10; &#125;&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#10;&#10; iap &#61; object&#40;&#123;&#10; oauth2_client_id &#61; string&#10; oauth2_client_secret &#61; string&#10; oauth2_client_secret_sha256 &#61; string&#10; &#125;&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [forwarding_rule_config](variables.tf#L226) | Regional forwarding rule configurations. | <code title="object&#40;&#123;&#10; ip_protocol &#61; string&#10; ip_version &#61; string&#10; load_balancing_scheme &#61; string&#10; port_range &#61; string&#10; network_tier &#61; string&#10; network &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; load_balancing_scheme &#61; &#34;EXTERNAL_MANAGED&#34;&#10; ip_protocol &#61; &#34;TCP&#34;&#10; ip_version &#61; &#34;IPV4&#34;&#10; network_tier &#61; &#34;STANDARD&#34;&#10; network &#61; &#34;default&#34;&#10; port_range &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [global_forwarding_rule_config](variables.tf#L208) | Global forwarding rule configurations. | <code title="object&#40;&#123;&#10; ip_protocol &#61; string&#10; ip_version &#61; string&#10; load_balancing_scheme &#61; string&#10; port_range &#61; string&#10;&#10;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; load_balancing_scheme &#61; &#34;EXTERNAL&#34;&#10; ip_protocol &#61; &#34;TCP&#34;&#10; ip_version &#61; &#34;IPV4&#34;&#10; port_range &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [health_checks_config](variables.tf#L51) | Custom health checks configuration. | <code title="map&#40;object&#40;&#123;&#10; type &#61; string &#35; http https tcp ssl http2&#10; check &#61; map&#40;any&#41; &#35; actual health check block attributes&#10; options &#61; map&#40;number&#41; &#35; interval, thresholds, timeout&#10; logging &#61; bool&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [health_checks_config_defaults](variables.tf#L33) | Auto-created health check default configuration. | <code title="object&#40;&#123;&#10; type &#61; string &#35; http https tcp ssl http2&#10; check &#61; map&#40;any&#41; &#35; actual health check block attributes&#10; options &#61; map&#40;number&#41; &#35; interval, thresholds, timeout&#10; logging &#61; bool&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; type &#61; &#34;http&#34;&#10; logging &#61; false&#10; options &#61; &#123;&#125;&#10; check &#61; &#123;&#10; port_specification &#61; &#34;USE_SERVING_PORT&#34;&#10; &#125;&#10;&#125;">&#123;&#8230;&#125;</code> |
| [https](variables.tf#L247) | Whether to enable HTTPS. | <code>bool</code> | | <code>false</code> |
| [region](variables.tf#L27) | Create a regional load balancer in this region. | <code>string</code> | | <code>null</code> |
| [reserve_ip_address](variables.tf#L253) | Whether to reserve a static global IP address. | <code>bool</code> | | <code>false</code> |
| [ssl_certificates_config](variables.tf#L171) | The SSL certificate configuration. | <code title="map&#40;object&#40;&#123;&#10; domains &#61; list&#40;string&#41;&#10; unmanaged_config &#61; object&#40;&#123;&#10; tls_private_key &#61; string&#10; tls_self_signed_cert &#61; string&#10; &#125;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [ssl_certificates_config_defaults](variables.tf#L184) | The SSL certificate default configuration. | <code title="object&#40;&#123;&#10; domains &#61; list&#40;string&#41;&#10; unmanaged_config &#61; object&#40;&#123;&#10; tls_private_key &#61; string&#10; tls_self_signed_cert &#61; string&#10; &#125;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; domains &#61; &#91;&#34;example.com&#34;&#93;,&#10; unmanaged_config &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [target_proxy_https_config](variables.tf#L200) | The HTTPS target proxy configuration. | <code title="object&#40;&#123;&#10; ssl_certificates &#61; list&#40;string&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [url_map_config](variables.tf#L157) | The url-map configuration. | <code title="object&#40;&#123;&#10; default_service &#61; string&#10; default_route_action &#61; any&#10; default_url_redirect &#61; map&#40;any&#41;&#10; header_action &#61; any&#10; host_rules &#61; list&#40;any&#41;&#10; path_matchers &#61; list&#40;any&#41;&#10; tests &#61; list&#40;map&#40;string&#41;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [name](variables.tf#L186) | Load balancer name. | <code>string</code> | ✓ | |
| [project_id](variables.tf#L191) | Project id. | <code>string</code> | ✓ | |
| [backend_services_config](variables.tf#L17) | The backends services configuration. | <code title="map&#40;object&#40;&#123;&#10; enable_cdn &#61; bool&#10;&#10;&#10; cdn_config &#61; object&#40;&#123;&#10; cache_mode &#61; string&#10; client_ttl &#61; number&#10; default_ttl &#61; number&#10; max_ttl &#61; number&#10; negative_caching &#61; bool&#10; negative_caching_policy &#61; map&#40;number&#41;&#10; serve_while_stale &#61; bool&#10; signed_url_cache_max_age_sec &#61; string&#10; &#125;&#41;&#10;&#10;&#10; bucket_config &#61; object&#40;&#123;&#10; bucket_name &#61; string&#10; options &#61; object&#40;&#123;&#10; custom_response_headers &#61; list&#40;string&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#10;&#10; group_config &#61; object&#40;&#123;&#10; backends &#61; list&#40;object&#40;&#123;&#10; group &#61; string &#35; IG or NEG FQDN address&#10; options &#61; object&#40;&#123;&#10; balancing_mode &#61; string &#35; Can be UTILIZATION, RATE, CONNECTION&#10; capacity_scaler &#61; number &#35; Valid range is &#91;0.0,1.0&#93;&#10; max_connections &#61; number&#10; max_connections_per_instance &#61; number&#10; max_connections_per_endpoint &#61; number&#10; max_rate &#61; number&#10; max_rate_per_instance &#61; number&#10; max_rate_per_endpoint &#61; number&#10; max_utilization &#61; number&#10; &#125;&#41;&#10; &#125;&#41;&#41;&#10; health_checks &#61; list&#40;string&#41;&#10;&#10;&#10; log_config &#61; object&#40;&#123;&#10; enable &#61; bool&#10; sample_rate &#61; number &#35; must be in &#91;0, 1&#93;&#10; &#125;&#41;&#10;&#10;&#10; options &#61; object&#40;&#123;&#10; affinity_cookie_ttl_sec &#61; number&#10; custom_request_headers &#61; list&#40;string&#41;&#10; custom_response_headers &#61; list&#40;string&#41;&#10; connection_draining_timeout_sec &#61; number&#10; load_balancing_scheme &#61; string &#35; only EXTERNAL &#40;default&#41; makes sense here&#10; locality_lb_policy &#61; string&#10; port_name &#61; string&#10; protocol &#61; string&#10; security_policy &#61; string&#10; session_affinity &#61; string&#10; timeout_sec &#61; number&#10;&#10;&#10; circuits_breakers &#61; object&#40;&#123;&#10; max_requests_per_connection &#61; number &#35; Set to 1 to disable keep-alive&#10; max_connections &#61; number &#35; Defaults to 1024&#10; max_pending_requests &#61; number &#35; Defaults to 1024&#10; max_requests &#61; number &#35; Defaults to 1024&#10; max_retries &#61; number &#35; Defaults to 3&#10; &#125;&#41;&#10;&#10;&#10; consistent_hash &#61; object&#40;&#123;&#10; http_header_name &#61; string&#10; minimum_ring_size &#61; string&#10; http_cookie &#61; object&#40;&#123;&#10; name &#61; string&#10; path &#61; string&#10; ttl &#61; object&#40;&#123;&#10; seconds &#61; number&#10; nanos &#61; number&#10; &#125;&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#10;&#10; iap &#61; object&#40;&#123;&#10; oauth2_client_id &#61; string&#10; oauth2_client_secret &#61; string&#10; oauth2_client_secret_sha256 &#61; string&#10; &#125;&#41;&#10; &#125;&#41;&#10; &#125;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [forwarding_rule_config](variables.tf#L112) | Regional forwarding rule configurations. | <code title="object&#40;&#123;&#10; ip_protocol &#61; string&#10; ip_version &#61; string&#10; load_balancing_scheme &#61; string&#10; port_range &#61; string&#10; network_tier &#61; string&#10; network &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; load_balancing_scheme &#61; &#34;EXTERNAL_MANAGED&#34;&#10; ip_protocol &#61; &#34;TCP&#34;&#10; ip_version &#61; &#34;IPV4&#34;&#10; network_tier &#61; &#34;STANDARD&#34;&#10; network &#61; &#34;default&#34;&#10; port_range &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [global_forwarding_rule_config](variables.tf#L133) | Global forwarding rule configurations. | <code title="object&#40;&#123;&#10; ip_protocol &#61; string&#10; ip_version &#61; string&#10; load_balancing_scheme &#61; string&#10; port_range &#61; string&#10;&#10;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; load_balancing_scheme &#61; &#34;EXTERNAL&#34;&#10; ip_protocol &#61; &#34;TCP&#34;&#10; ip_version &#61; &#34;IPV4&#34;&#10; port_range &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [health_checks_config](variables.tf#L151) | Custom health checks configuration. | <code title="map&#40;object&#40;&#123;&#10; type &#61; string &#35; http https tcp ssl http2&#10; check &#61; map&#40;any&#41; &#35; actual health check block attributes&#10; options &#61; map&#40;number&#41; &#35; interval, thresholds, timeout&#10; logging &#61; bool&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [health_checks_config_defaults](variables.tf#L162) | Auto-created health check default configuration. | <code title="object&#40;&#123;&#10; type &#61; string &#35; http https tcp ssl http2&#10; check &#61; map&#40;any&#41; &#35; actual health check block attributes&#10; options &#61; map&#40;number&#41; &#35; interval, thresholds, timeout&#10; logging &#61; bool&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; type &#61; &#34;http&#34;&#10; logging &#61; false&#10; options &#61; &#123;&#125;&#10; check &#61; &#123;&#10; port_specification &#61; &#34;USE_SERVING_PORT&#34;&#10; &#125;&#10;&#125;">&#123;&#8230;&#125;</code> |
| [https](variables.tf#L180) | Whether to enable HTTPS. | <code>bool</code> | | <code>false</code> |
| [region](variables.tf#L196) | Create a regional load balancer in this region. | <code>string</code> | | <code>null</code> |
| [reserve_ip_address](variables.tf#L202) | Whether to reserve a static global IP address. | <code>bool</code> | | <code>false</code> |
| [ssl_certificates_config](variables.tf#L208) | The SSL certificate configuration. | <code title="map&#40;object&#40;&#123;&#10; domains &#61; list&#40;string&#41;&#10; unmanaged_config &#61; object&#40;&#123;&#10; tls_private_key &#61; string&#10; tls_self_signed_cert &#61; string&#10; &#125;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [ssl_certificates_config_defaults](variables.tf#L221) | The SSL certificate default configuration. | <code title="object&#40;&#123;&#10; domains &#61; list&#40;string&#41;&#10; unmanaged_config &#61; object&#40;&#123;&#10; tls_private_key &#61; string&#10; tls_self_signed_cert &#61; string&#10; &#125;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code title="&#123;&#10; domains &#61; &#91;&#34;example.com&#34;&#93;,&#10; unmanaged_config &#61; null&#10;&#125;">&#123;&#8230;&#125;</code> |
| [target_proxy_https_config](variables.tf#L237) | The HTTPS target proxy configuration. | <code title="object&#40;&#123;&#10; ssl_certificates &#61; list&#40;string&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [url_map_config](variables.tf#L245) | The url-map configuration. | <code title="object&#40;&#123;&#10; default_service &#61; string&#10; default_route_action &#61; any&#10; default_url_redirect &#61; map&#40;any&#41;&#10; header_action &#61; any&#10; host_rules &#61; list&#40;any&#41;&#10; path_matchers &#61; list&#40;any&#41;&#10; tests &#61; list&#40;map&#40;string&#41;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
## Outputs
| name | description | sensitive |
|---|---|:---:|
| [backend_services](outputs.tf#L22) | Backend service resources. | |
| [forwarding_rule](outputs.tf#L67) | The regional forwarding rule. | |
| [global_forwarding_rule](outputs.tf#L62) | The global forwarding rule. | |
| [health_checks](outputs.tf#L17) | Health-check resources. | |
| [ip_address](outputs.tf#L44) | The reserved global IP address. | |
| [ip_address_self_link](outputs.tf#L49) | The URI of the reserved global IP address. | |
| [ssl_certificates](outputs.tf#L35) | The SSL certificate. | |
| [target_proxy](outputs.tf#L54) | The target proxy. | |
| [url_map](outputs.tf#L30) | The url-map. | |
| [backend_services](outputs.tf#L17) | Backend service resources. | |
| [forwarding_rule](outputs.tf#L25) | The regional forwarding rule. | |
| [global_forwarding_rule](outputs.tf#L30) | The global forwarding rule. | |
| [health_checks](outputs.tf#L35) | Health-check resources. | |
| [ip_address](outputs.tf#L40) | The reserved global IP address. | |
| [ip_address_self_link](outputs.tf#L45) | The URI of the reserved global IP address. | |
| [ssl_certificates](outputs.tf#L50) | The SSL certificate. | |
| [target_proxy](outputs.tf#L59) | The target proxy. | |
| [url_map](outputs.tf#L67) | The url-map. | |
<!-- END TFDOC -->

View File

@@ -14,11 +14,6 @@
* limitations under the License.
*/
output "health_checks" {
description = "Health-check resources."
value = try(google_compute_health_check.health_check, [])
}
output "backend_services" {
description = "Backend service resources."
value = {
@@ -27,18 +22,19 @@ output "backend_services" {
}
}
output "url_map" {
description = "The url-map."
value = google_compute_url_map.url_map
output "forwarding_rule" {
description = "The regional forwarding rule."
value = var.region == null ? google_compute_global_forwarding_rule.forwarding_rule.0 : google_compute_forwarding_rule.forwarding_rule.0
}
output "ssl_certificates" {
description = "The SSL certificate."
value = try(
google_compute_managed_ssl_certificate.managed,
google_compute_ssl_certificate.unmanaged,
null
)
output "global_forwarding_rule" {
description = "The global forwarding rule."
value = var.region == null ? google_compute_global_forwarding_rule.forwarding_rule.0 : null
}
output "health_checks" {
description = "Health-check resources."
value = try(google_compute_health_check.health_check, [])
}
output "ip_address" {
@@ -51,6 +47,15 @@ output "ip_address_self_link" {
value = var.region == null ? google_compute_global_forwarding_rule.forwarding_rule.0.ip_address : google_compute_forwarding_rule.forwarding_rule.0.ip_address
}
output "ssl_certificates" {
description = "The SSL certificate."
value = try(
google_compute_managed_ssl_certificate.managed,
google_compute_ssl_certificate.unmanaged,
null
)
}
output "target_proxy" {
description = "The target proxy."
value = try(
@@ -59,12 +64,7 @@ output "target_proxy" {
)
}
output "global_forwarding_rule" {
description = "The global forwarding rule."
value = var.region == null ? google_compute_global_forwarding_rule.forwarding_rule.0 : null
}
output "forwarding_rule" {
description = "The regional forwarding rule."
value = var.region == null ? google_compute_global_forwarding_rule.forwarding_rule.0 : google_compute_forwarding_rule.forwarding_rule.0
output "url_map" {
description = "The url-map."
value = google_compute_url_map.url_map
}

View File

@@ -14,51 +14,6 @@
* limitations under the License.
*/
variable "name" {
description = "Load balancer name."
type = string
}
variable "project_id" {
description = "Project id."
type = string
}
variable "region" {
description = "Create a regional load balancer in this region."
type = string
default = null
}
variable "health_checks_config_defaults" {
description = "Auto-created health check default configuration."
type = object({
type = string # http https tcp ssl http2
check = map(any) # actual health check block attributes
options = map(number) # interval, thresholds, timeout
logging = bool
})
default = {
type = "http"
logging = false
options = {}
check = {
port_specification = "USE_SERVING_PORT"
}
}
}
variable "health_checks_config" {
description = "Custom health checks configuration."
type = map(object({
type = string # http https tcp ssl http2
check = map(any) # actual health check block attributes
options = map(number) # interval, thresholds, timeout
logging = bool
}))
default = {}
}
variable "backend_services_config" {
description = "The backends services configuration."
type = map(object({
@@ -154,18 +109,100 @@ variable "backend_services_config" {
default = {}
}
variable "url_map_config" {
description = "The url-map configuration."
variable "forwarding_rule_config" {
description = "Regional forwarding rule configurations."
type = object({
default_service = string
default_route_action = any
default_url_redirect = map(any)
header_action = any
host_rules = list(any)
path_matchers = list(any)
tests = list(map(string))
ip_protocol = string
ip_version = string
load_balancing_scheme = string
port_range = string
network_tier = string
network = string
})
default = null
default = {
load_balancing_scheme = "EXTERNAL_MANAGED"
ip_protocol = "TCP"
ip_version = "IPV4"
network_tier = "STANDARD"
network = "default"
# If not specified, 80 for https = false, 443 otherwise
port_range = null
}
}
variable "global_forwarding_rule_config" {
description = "Global forwarding rule configurations."
type = object({
ip_protocol = string
ip_version = string
load_balancing_scheme = string
port_range = string
})
default = {
load_balancing_scheme = "EXTERNAL"
ip_protocol = "TCP"
ip_version = "IPV4"
# If not specified, 80 for https = false, 443 otherwise
port_range = null
}
}
variable "health_checks_config" {
description = "Custom health checks configuration."
type = map(object({
type = string # http https tcp ssl http2
check = map(any) # actual health check block attributes
options = map(number) # interval, thresholds, timeout
logging = bool
}))
default = {}
}
variable "health_checks_config_defaults" {
description = "Auto-created health check default configuration."
type = object({
type = string # http https tcp ssl http2
check = map(any) # actual health check block attributes
options = map(number) # interval, thresholds, timeout
logging = bool
})
default = {
type = "http"
logging = false
options = {}
check = {
port_specification = "USE_SERVING_PORT"
}
}
}
variable "https" {
description = "Whether to enable HTTPS."
type = bool
default = false
}
variable "name" {
description = "Load balancer name."
type = string
}
variable "project_id" {
description = "Project id."
type = string
}
variable "region" {
description = "Create a regional load balancer in this region."
type = string
default = null
}
variable "reserve_ip_address" {
description = "Whether to reserve a static global IP address."
type = bool
default = false
}
variable "ssl_certificates_config" {
@@ -205,53 +242,16 @@ variable "target_proxy_https_config" {
default = null
}
variable "global_forwarding_rule_config" {
description = "Global forwarding rule configurations."
variable "url_map_config" {
description = "The url-map configuration."
type = object({
ip_protocol = string
ip_version = string
load_balancing_scheme = string
port_range = string
default_service = string
default_route_action = any
default_url_redirect = map(any)
header_action = any
host_rules = list(any)
path_matchers = list(any)
tests = list(map(string))
})
default = {
load_balancing_scheme = "EXTERNAL"
ip_protocol = "TCP"
ip_version = "IPV4"
# If not specified, 80 for https = false, 443 otherwise
port_range = null
}
}
variable "forwarding_rule_config" {
description = "Regional forwarding rule configurations."
type = object({
ip_protocol = string
ip_version = string
load_balancing_scheme = string
port_range = string
network_tier = string
network = string
})
default = {
load_balancing_scheme = "EXTERNAL_MANAGED"
ip_protocol = "TCP"
ip_version = "IPV4"
network_tier = "STANDARD"
network = "default"
# If not specified, 80 for https = false, 443 otherwise
port_range = null
}
}
variable "https" {
description = "Whether to enable HTTPS."
type = bool
default = false
}
variable "reserve_ip_address" {
description = "Whether to reserve a static global IP address."
type = bool
default = false
default = null
}

View File

@@ -146,8 +146,8 @@ module "ilb" {
| [forwarding_rule_address](outputs.tf#L37) | Forwarding rule address. | |
| [forwarding_rule_id](outputs.tf#L42) | Forwarding rule id. | |
| [forwarding_rule_self_link](outputs.tf#L47) | Forwarding rule self link. | |
| [group_self_links](outputs.tf#L57) | Optional unmanaged instance group self links. | |
| [groups](outputs.tf#L52) | Optional unmanaged instance group resources. | |
| [group_self_links](outputs.tf#L52) | Optional unmanaged instance group self links. | |
| [groups](outputs.tf#L59) | Optional unmanaged instance group resources. | |
| [health_check](outputs.tf#L64) | Auto-created health-check resource. | |
| [health_check_self_id](outputs.tf#L69) | Auto-created health-check self id. | |
| [health_check_self_link](outputs.tf#L74) | Auto-created health-check self link. | |

View File

@@ -49,11 +49,6 @@ output "forwarding_rule_self_link" {
value = google_compute_forwarding_rule.default.self_link
}
output "groups" {
description = "Optional unmanaged instance group resources."
value = google_compute_instance_group.unmanaged
}
output "group_self_links" {
description = "Optional unmanaged instance group self links."
value = {
@@ -61,6 +56,11 @@ output "group_self_links" {
}
}
output "groups" {
description = "Optional unmanaged instance group resources."
value = google_compute_instance_group.unmanaged
}
output "health_check" {
description = "Auto-created health-check resource."
value = try(google_compute_health_check.default.0, null)

View File

@@ -178,8 +178,8 @@ healthchecks:
| [project_id](variables.tf#L114) | Project id of the project that holds the network. | <code>string</code> | ✓ | |
| [default_rules_config](variables.tf#L17) | Optionally created convenience rules. Set the variable or individual members to null to disable. | <code title="object&#40;&#123;&#10; admin_ranges &#61; optional&#40;list&#40;string&#41;&#41;&#10; disabled &#61; optional&#40;bool, false&#41;&#10; http_ranges &#61; optional&#40;list&#40;string&#41;, &#91;&#10; &#34;35.191.0.0&#47;16&#34;, &#34;130.211.0.0&#47;22&#34;, &#34;209.85.152.0&#47;22&#34;, &#34;209.85.204.0&#47;22&#34;&#93;&#10; &#41;&#10; http_tags &#61; optional&#40;list&#40;string&#41;, &#91;&#34;http-server&#34;&#93;&#41;&#10; https_ranges &#61; optional&#40;list&#40;string&#41;, &#91;&#10; &#34;35.191.0.0&#47;16&#34;, &#34;130.211.0.0&#47;22&#34;, &#34;209.85.152.0&#47;22&#34;, &#34;209.85.204.0&#47;22&#34;&#93;&#10; &#41;&#10; https_tags &#61; optional&#40;list&#40;string&#41;, &#91;&#34;https-server&#34;&#93;&#41;&#10; ssh_ranges &#61; optional&#40;list&#40;string&#41;, &#91;&#34;35.235.240.0&#47;20&#34;&#93;&#41;&#10; ssh_tags &#61; optional&#40;list&#40;string&#41;, &#91;&#34;ssh&#34;&#93;&#41;&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>&#123;&#125;</code> |
| [egress_rules](variables.tf#L37) | List of egress rule definitions, default to deny action. | <code title="map&#40;object&#40;&#123;&#10; deny &#61; optional&#40;bool, true&#41;&#10; description &#61; optional&#40;string&#41;&#10; destination_ranges &#61; optional&#40;list&#40;string&#41;&#41;&#10; disabled &#61; optional&#40;bool, false&#41;&#10; enable_logging &#61; optional&#40;object&#40;&#123;&#10; include_metadata &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;&#10; priority &#61; optional&#40;number, 1000&#41;&#10; sources &#61; optional&#40;list&#40;string&#41;&#41;&#10; targets &#61; optional&#40;list&#40;string&#41;&#41;&#10; use_service_accounts &#61; optional&#40;bool, false&#41;&#10; rules &#61; optional&#40;list&#40;object&#40;&#123;&#10; protocol &#61; string&#10; ports &#61; optional&#40;list&#40;string&#41;&#41;&#10; &#125;&#41;&#41;, &#91;&#123; protocol &#61; &#34;all&#34; &#125;&#93;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [factories_config](variables.tf#L83) | Paths to data files and folders that enable factory functionality. | <code title="object&#40;&#123;&#10; cidr_tpl_file &#61; optional&#40;string&#41;&#10; rules_folder &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [ingress_rules](variables.tf#L60) | List of ingress rule definitions, default to allow action. | <code title="map&#40;object&#40;&#123;&#10; deny &#61; optional&#40;bool, false&#41;&#10; description &#61; optional&#40;string&#41;&#10; disabled &#61; optional&#40;bool, false&#41;&#10; enable_logging &#61; optional&#40;object&#40;&#123;&#10; include_metadata &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;&#10; priority &#61; optional&#40;number, 1000&#41;&#10; source_ranges &#61; optional&#40;list&#40;string&#41;&#41;&#10; sources &#61; optional&#40;list&#40;string&#41;&#41;&#10; targets &#61; optional&#40;list&#40;string&#41;&#41;&#10; use_service_accounts &#61; optional&#40;bool, false&#41;&#10; rules &#61; optional&#40;list&#40;object&#40;&#123;&#10; protocol &#61; string&#10; ports &#61; optional&#40;list&#40;string&#41;&#41;&#10; &#125;&#41;&#41;, &#91;&#123; protocol &#61; &#34;all&#34; &#125;&#93;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [factories_config](variables.tf#L60) | Paths to data files and folders that enable factory functionality. | <code title="object&#40;&#123;&#10; cidr_tpl_file &#61; optional&#40;string&#41;&#10; rules_folder &#61; string&#10;&#125;&#41;">object&#40;&#123;&#8230;&#125;&#41;</code> | | <code>null</code> |
| [ingress_rules](variables.tf#L69) | List of ingress rule definitions, default to allow action. | <code title="map&#40;object&#40;&#123;&#10; deny &#61; optional&#40;bool, false&#41;&#10; description &#61; optional&#40;string&#41;&#10; disabled &#61; optional&#40;bool, false&#41;&#10; enable_logging &#61; optional&#40;object&#40;&#123;&#10; include_metadata &#61; optional&#40;bool&#41;&#10; &#125;&#41;&#41;&#10; priority &#61; optional&#40;number, 1000&#41;&#10; source_ranges &#61; optional&#40;list&#40;string&#41;&#41;&#10; sources &#61; optional&#40;list&#40;string&#41;&#41;&#10; targets &#61; optional&#40;list&#40;string&#41;&#41;&#10; use_service_accounts &#61; optional&#40;bool, false&#41;&#10; rules &#61; optional&#40;list&#40;object&#40;&#123;&#10; protocol &#61; string&#10; ports &#61; optional&#40;list&#40;string&#41;&#41;&#10; &#125;&#41;&#41;, &#91;&#123; protocol &#61; &#34;all&#34; &#125;&#93;&#41;&#10;&#125;&#41;&#41;">map&#40;object&#40;&#123;&#8230;&#125;&#41;&#41;</code> | | <code>&#123;&#125;</code> |
| [named_ranges](variables.tf#L92) | Define mapping of names to ranges that can be used in custom rules. | <code>map&#40;list&#40;string&#41;&#41;</code> | | <code title="&#123;&#10; any &#61; &#91;&#34;0.0.0.0&#47;0&#34;&#93;&#10; dns-forwarders &#61; &#91;&#34;35.199.192.0&#47;19&#34;&#93;&#10; health-checkers &#61; &#91;&#10; &#34;35.191.0.0&#47;16&#34;, &#34;130.211.0.0&#47;22&#34;, &#34;209.85.152.0&#47;22&#34;, &#34;209.85.204.0&#47;22&#34;&#10; &#93;&#10; iap-forwarders &#61; &#91;&#34;35.235.240.0&#47;20&#34;&#93;&#10; private-googleapis &#61; &#91;&#34;199.36.153.8&#47;30&#34;&#93;&#10; restricted-googleapis &#61; &#91;&#34;199.36.153.4&#47;30&#34;&#93;&#10; rfc1918 &#61; &#91;&#34;10.0.0.0&#47;8&#34;, &#34;172.16.0.0&#47;12&#34;, &#34;192.168.0.0&#47;16&#34;&#93;&#10;&#125;">&#123;&#8230;&#125;</code> |
## Outputs

View File

@@ -57,6 +57,15 @@ variable "egress_rules" {
nullable = false
}
variable "factories_config" {
description = "Paths to data files and folders that enable factory functionality."
type = object({
cidr_tpl_file = optional(string)
rules_folder = string
})
default = null
}
variable "ingress_rules" {
description = "List of ingress rule definitions, default to allow action."
type = map(object({
@@ -80,15 +89,6 @@ variable "ingress_rules" {
nullable = false
}
variable "factories_config" {
description = "Paths to data files and folders that enable factory functionality."
type = object({
cidr_tpl_file = optional(string)
rules_folder = string
})
default = null
}
variable "named_ranges" {
description = "Define mapping of names to ranges that can be used in custom rules."
type = map(list(string))

View File

@@ -50,15 +50,15 @@ output "dev-folders" {
| name | description | type | required | default |
|---|---|:---:|:---:|:---:|
| [parent](variables.tf#L17) | Parent folder or organization in 'folders/folder_id' or 'organizations/org_id' format. | <code>string</code> | ✓ | |
| [filter](variables.tf#L26) | A string filter as defined in the [REST API](https://cloud.google.com/resource-manager/reference/rest/v1/projects/list#query-parameters). | <code>string</code> | | <code>&#34;lifecycleState:ACTIVE&#34;</code> |
| [parent](variables.tf#L23) | Parent folder or organization in 'folders/folder_id' or 'organizations/org_id' format. | <code>string</code> | ✓ | |
| [filter](variables.tf#L17) | A string filter as defined in the [REST API](https://cloud.google.com/resource-manager/reference/rest/v1/projects/list#query-parameters). | <code>string</code> | | <code>&#34;lifecycleState:ACTIVE&#34;</code> |
## Outputs
| name | description | sensitive |
|---|---|:---:|
| [folders](outputs.tf#L17) | Map of folders attributes keyed by folder id. | |
| [project_numbers](outputs.tf#L27) | List of project numbers. | |
| [projects](outputs.tf#L22) | Map of projects attributes keyed by projects id. | |
| [project_numbers](outputs.tf#L22) | List of project numbers. | |
| [projects](outputs.tf#L27) | Map of projects attributes keyed by projects id. | |
<!-- END TFDOC -->

View File

@@ -19,12 +19,12 @@ output "folders" {
value = local.all_folders
}
output "projects" {
description = "Map of projects attributes keyed by projects id."
value = local.projects
}
output "project_numbers" {
description = "List of project numbers."
value = [for _, v in local.projects : v.number]
}
output "projects" {
description = "Map of projects attributes keyed by projects id."
value = local.projects
}

View File

@@ -14,6 +14,12 @@
* limitations under the License.
*/
variable "filter" {
description = "A string filter as defined in the [REST API](https://cloud.google.com/resource-manager/reference/rest/v1/projects/list#query-parameters)."
type = string
default = "lifecycleState:ACTIVE"
}
variable "parent" {
description = "Parent folder or organization in 'folders/folder_id' or 'organizations/org_id' format."
type = string
@@ -22,9 +28,3 @@ variable "parent" {
error_message = "Parent must be of the form folders/folder_id or organizations/organization_id."
}
}
variable "filter" {
description = "A string filter as defined in the [REST API](https://cloud.google.com/resource-manager/reference/rest/v1/projects/list#query-parameters)."
type = string
default = "lifecycleState:ACTIVE"
}