allow to configure `stack_type` in the GKE modules (#1395)
Co-authored-by: Ludovico Magnocavallo <ludomagno@google.com>
This commit is contained in:
parent
4aa99ea829
commit
aa80109081
|
@ -99,7 +99,7 @@ module "cluster-1" {
|
||||||
| [location](variables.tf#L110) | Autopilot cluster are always regional. | <code>string</code> | ✓ | |
|
| [location](variables.tf#L110) | Autopilot cluster are always regional. | <code>string</code> | ✓ | |
|
||||||
| [name](variables.tf#L145) | Cluster name. | <code>string</code> | ✓ | |
|
| [name](variables.tf#L145) | Cluster name. | <code>string</code> | ✓ | |
|
||||||
| [project_id](variables.tf#L171) | Cluster project id. | <code>string</code> | ✓ | |
|
| [project_id](variables.tf#L171) | Cluster project id. | <code>string</code> | ✓ | |
|
||||||
| [vpc_config](variables.tf#L194) | VPC-level configuration. | <code title="object({ network = string subnetwork = string master_ipv4_cidr_block = optional(string) secondary_range_blocks = optional(object({ pods = string services = string })) secondary_range_names = optional(object({ pods = string services = string }), { pods = "pods", services = "services" }) master_authorized_ranges = optional(map(string)) })">object({…})</code> | ✓ | |
|
| [vpc_config](variables.tf#L194) | VPC-level configuration. | <code title="object({ network = string subnetwork = string master_ipv4_cidr_block = optional(string) secondary_range_blocks = optional(object({ pods = string services = string })) secondary_range_names = optional(object({ pods = string services = string }), { pods = "pods", services = "services" }) master_authorized_ranges = optional(map(string)) stack_type = optional(string) })">object({…})</code> | ✓ | |
|
||||||
| [backup_configs](variables.tf#L17) | Configuration for Backup for GKE. | <code title="object({ enable_backup_agent = optional(bool, false) backup_plans = optional(map(object({ encryption_key = optional(string) include_secrets = optional(bool, true) include_volume_data = optional(bool, true) namespaces = optional(list(string)) region = string schedule = string retention_policy_days = optional(string) retention_policy_lock = optional(bool, false) retention_policy_delete_lock_days = optional(string) })), {}) })">object({…})</code> | | <code>{}</code> |
|
| [backup_configs](variables.tf#L17) | Configuration for Backup for GKE. | <code title="object({ enable_backup_agent = optional(bool, false) backup_plans = optional(map(object({ encryption_key = optional(string) include_secrets = optional(bool, true) include_volume_data = optional(bool, true) namespaces = optional(list(string)) region = string schedule = string retention_policy_days = optional(string) retention_policy_lock = optional(bool, false) retention_policy_delete_lock_days = optional(string) })), {}) })">object({…})</code> | | <code>{}</code> |
|
||||||
| [description](variables.tf#L37) | Cluster description. | <code>string</code> | | <code>null</code> |
|
| [description](variables.tf#L37) | Cluster description. | <code>string</code> | | <code>null</code> |
|
||||||
| [enable_addons](variables.tf#L43) | Addons enabled in the cluster (true means enabled). | <code title="object({ cloudrun = optional(bool, false) config_connector = optional(bool, false) dns_cache = optional(bool, false) horizontal_pod_autoscaling = optional(bool, false) http_load_balancing = optional(bool, false) istio = optional(object({ enable_tls = bool })) kalm = optional(bool, false) network_policy = optional(bool, false) })">object({…})</code> | | <code title="{ horizontal_pod_autoscaling = true http_load_balancing = true }">{…}</code> |
|
| [enable_addons](variables.tf#L43) | Addons enabled in the cluster (true means enabled). | <code title="object({ cloudrun = optional(bool, false) config_connector = optional(bool, false) dns_cache = optional(bool, false) horizontal_pod_autoscaling = optional(bool, false) http_load_balancing = optional(bool, false) istio = optional(object({ enable_tls = bool })) kalm = optional(bool, false) network_policy = optional(bool, false) })">object({…})</code> | | <code title="{ horizontal_pod_autoscaling = true http_load_balancing = true }">{…}</code> |
|
||||||
|
|
|
@ -100,6 +100,7 @@ resource "google_container_cluster" "cluster" {
|
||||||
content {
|
content {
|
||||||
cluster_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.pods
|
cluster_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.pods
|
||||||
services_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.services
|
services_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.services
|
||||||
|
stack_type = try(var.vpc_config.stack_type, null)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,6 +109,7 @@ resource "google_container_cluster" "cluster" {
|
||||||
content {
|
content {
|
||||||
cluster_secondary_range_name = var.vpc_config.secondary_range_names.pods
|
cluster_secondary_range_name = var.vpc_config.secondary_range_names.pods
|
||||||
services_secondary_range_name = var.vpc_config.secondary_range_names.services
|
services_secondary_range_name = var.vpc_config.secondary_range_names.services
|
||||||
|
stack_type = try(var.vpc_config.stack_type, null)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -206,6 +206,7 @@ variable "vpc_config" {
|
||||||
services = string
|
services = string
|
||||||
}), { pods = "pods", services = "services" })
|
}), { pods = "pods", services = "services" })
|
||||||
master_authorized_ranges = optional(map(string))
|
master_authorized_ranges = optional(map(string))
|
||||||
|
stack_type = optional(string)
|
||||||
})
|
})
|
||||||
nullable = false
|
nullable = false
|
||||||
}
|
}
|
||||||
|
|
|
@ -134,7 +134,7 @@ module "cluster-1" {
|
||||||
| [location](variables.tf#L137) | Cluster zone or region. | <code>string</code> | ✓ | |
|
| [location](variables.tf#L137) | Cluster zone or region. | <code>string</code> | ✓ | |
|
||||||
| [name](variables.tf#L194) | Cluster name. | <code>string</code> | ✓ | |
|
| [name](variables.tf#L194) | Cluster name. | <code>string</code> | ✓ | |
|
||||||
| [project_id](variables.tf#L220) | Cluster project id. | <code>string</code> | ✓ | |
|
| [project_id](variables.tf#L220) | Cluster project id. | <code>string</code> | ✓ | |
|
||||||
| [vpc_config](variables.tf#L237) | VPC-level configuration. | <code title="object({ network = string subnetwork = string master_ipv4_cidr_block = optional(string) secondary_range_blocks = optional(object({ pods = string services = string })) secondary_range_names = optional(object({ pods = string services = string }), { pods = "pods", services = "services" }) master_authorized_ranges = optional(map(string)) })">object({…})</code> | ✓ | |
|
| [vpc_config](variables.tf#L237) | VPC-level configuration. | <code title="object({ network = string subnetwork = string master_ipv4_cidr_block = optional(string) secondary_range_blocks = optional(object({ pods = string services = string })) secondary_range_names = optional(object({ pods = string services = string }), { pods = "pods", services = "services" }) master_authorized_ranges = optional(map(string)) stack_type = optional(string) })">object({…})</code> | ✓ | |
|
||||||
| [backup_configs](variables.tf#L17) | Configuration for Backup for GKE. | <code title="object({ enable_backup_agent = optional(bool, false) backup_plans = optional(map(object({ encryption_key = optional(string) include_secrets = optional(bool, true) include_volume_data = optional(bool, true) namespaces = optional(list(string)) region = string schedule = string retention_policy_days = optional(string) retention_policy_lock = optional(bool, false) retention_policy_delete_lock_days = optional(string) })), {}) })">object({…})</code> | | <code>{}</code> |
|
| [backup_configs](variables.tf#L17) | Configuration for Backup for GKE. | <code title="object({ enable_backup_agent = optional(bool, false) backup_plans = optional(map(object({ encryption_key = optional(string) include_secrets = optional(bool, true) include_volume_data = optional(bool, true) namespaces = optional(list(string)) region = string schedule = string retention_policy_days = optional(string) retention_policy_lock = optional(bool, false) retention_policy_delete_lock_days = optional(string) })), {}) })">object({…})</code> | | <code>{}</code> |
|
||||||
| [cluster_autoscaling](variables.tf#L37) | Enable and configure limits for Node Auto-Provisioning with Cluster Autoscaler. | <code title="object({ auto_provisioning_defaults = optional(object({ boot_disk_kms_key = optional(string) image_type = optional(string) oauth_scopes = optional(list(string)) service_account = optional(string) })) cpu_limits = optional(object({ min = number max = number })) mem_limits = optional(object({ min = number max = number })) })">object({…})</code> | | <code>null</code> |
|
| [cluster_autoscaling](variables.tf#L37) | Enable and configure limits for Node Auto-Provisioning with Cluster Autoscaler. | <code title="object({ auto_provisioning_defaults = optional(object({ boot_disk_kms_key = optional(string) image_type = optional(string) oauth_scopes = optional(list(string)) service_account = optional(string) })) cpu_limits = optional(object({ min = number max = number })) mem_limits = optional(object({ min = number max = number })) })">object({…})</code> | | <code>null</code> |
|
||||||
| [description](variables.tf#L58) | Cluster description. | <code>string</code> | | <code>null</code> |
|
| [description](variables.tf#L58) | Cluster description. | <code>string</code> | | <code>null</code> |
|
||||||
|
|
|
@ -162,6 +162,7 @@ resource "google_container_cluster" "cluster" {
|
||||||
content {
|
content {
|
||||||
cluster_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.pods
|
cluster_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.pods
|
||||||
services_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.services
|
services_ipv4_cidr_block = var.vpc_config.secondary_range_blocks.services
|
||||||
|
stack_type = try(var.vpc_config.stack_type, null)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
dynamic "ip_allocation_policy" {
|
dynamic "ip_allocation_policy" {
|
||||||
|
@ -169,6 +170,7 @@ resource "google_container_cluster" "cluster" {
|
||||||
content {
|
content {
|
||||||
cluster_secondary_range_name = var.vpc_config.secondary_range_names.pods
|
cluster_secondary_range_name = var.vpc_config.secondary_range_names.pods
|
||||||
services_secondary_range_name = var.vpc_config.secondary_range_names.services
|
services_secondary_range_name = var.vpc_config.secondary_range_names.services
|
||||||
|
stack_type = try(var.vpc_config.stack_type, null)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -249,6 +249,7 @@ variable "vpc_config" {
|
||||||
services = string
|
services = string
|
||||||
}), { pods = "pods", services = "services" })
|
}), { pods = "pods", services = "services" })
|
||||||
master_authorized_ranges = optional(map(string))
|
master_authorized_ranges = optional(map(string))
|
||||||
|
stack_type = optional(string)
|
||||||
})
|
})
|
||||||
nullable = false
|
nullable = false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue