diff --git a/modules/gke-nodepool/README.md b/modules/gke-nodepool/README.md index 147320076..b2e1ec54b 100644 --- a/modules/gke-nodepool/README.md +++ b/modules/gke-nodepool/README.md @@ -218,7 +218,7 @@ module "cluster-1-nodepool-hyperdisk" { |---|---|:---:|:---:|:---:| | [cluster_name](variables.tf#L23) | Cluster name. | string | ✓ | | | [location](variables.tf#L48) | Cluster location. | string | ✓ | | -| [project_id](variables.tf#L224) | Cluster project id. | string | ✓ | | +| [project_id](variables.tf#L225) | Cluster project id. | string | ✓ | | | [cluster_id](variables.tf#L17) | Cluster id. Optional, but providing cluster_id is recommended to prevent cluster misconfiguration in some of the edge cases. | string | | null | | [gke_version](variables.tf#L28) | Kubernetes nodes version. Ignored if auto_upgrade is set in management_config. | string | | null | | [k8s_labels](variables.tf#L34) | Kubernetes labels applied to each node. | map(string) | | {} | @@ -227,15 +227,15 @@ module "cluster-1-nodepool-hyperdisk" { | [name](variables.tf#L59) | Optional nodepool name. | string | | null | | [network_config](variables.tf#L65) | Network configuration. | object({…}) | | null | | [node_config](variables.tf#L89) | Node-level configuration. | object({…}) | | {} | -| [node_count](variables.tf#L170) | Number of nodes per instance group. Initial value can only be changed by recreation, current is ignored when autoscaling is used. | object({…}) | | {…} | -| [node_locations](variables.tf#L182) | Node locations. | list(string) | | null | -| [nodepool_config](variables.tf#L188) | Nodepool-level configuration. | object({…}) | | null | -| [reservation_affinity](variables.tf#L229) | Configuration of the desired reservation which instances could take capacity from. | object({…}) | | null | -| [resource_manager_tags](variables.tf#L239) | A map of resource manager tag keys and values to be attached to the nodes for managing Compute Engine firewalls using Network Firewall Policies. | map(string) | | null | -| [service_account](variables.tf#L245) | Nodepool service account. If this variable is set to null, the default GCE service account will be used. If set and email is null, a service account will be created. If scopes are null a default will be used. | object({…}) | | {} | -| [sole_tenant_nodegroup](variables.tf#L257) | Sole tenant node group. | string | | null | -| [tags](variables.tf#L263) | Network tags applied to nodes. | list(string) | | null | -| [taints](variables.tf#L269) | Kubernetes taints applied to all nodes. | map(object({…})) | | {} | +| [node_count](variables.tf#L171) | Number of nodes per instance group. Initial value can only be changed by recreation, current is ignored when autoscaling is used. | object({…}) | | {…} | +| [node_locations](variables.tf#L183) | Node locations. | list(string) | | null | +| [nodepool_config](variables.tf#L189) | Nodepool-level configuration. | object({…}) | | null | +| [reservation_affinity](variables.tf#L230) | Configuration of the desired reservation which instances could take capacity from. | object({…}) | | null | +| [resource_manager_tags](variables.tf#L240) | A map of resource manager tag keys and values to be attached to the nodes for managing Compute Engine firewalls using Network Firewall Policies. | map(string) | | null | +| [service_account](variables.tf#L246) | Nodepool service account. If this variable is set to null, the default GCE service account will be used. If set and email is null, a service account will be created. If scopes are null a default will be used. | object({…}) | | {} | +| [sole_tenant_nodegroup](variables.tf#L258) | Sole tenant node group. | string | | null | +| [tags](variables.tf#L264) | Network tags applied to nodes. | list(string) | | null | +| [taints](variables.tf#L270) | Kubernetes taints applied to all nodes. | map(object({…})) | | {} | ## Outputs diff --git a/modules/gke-nodepool/main.tf b/modules/gke-nodepool/main.tf index cd809b6d7..92f948b79 100644 --- a/modules/gke-nodepool/main.tf +++ b/modules/gke-nodepool/main.tf @@ -217,6 +217,7 @@ resource "google_container_node_pool" "nodepool" { spot = ( var.node_config.spot == true && var.node_config.preemptible != true ) + flex_start = var.node_config.flex_start tags = var.tags resource_manager_tags = var.resource_manager_tags diff --git a/modules/gke-nodepool/variables.tf b/modules/gke-nodepool/variables.tf index c5540d590..294e3af11 100644 --- a/modules/gke-nodepool/variables.tf +++ b/modules/gke-nodepool/variables.tf @@ -143,6 +143,7 @@ variable "node_config" { enable_secure_boot = optional(bool) })) spot = optional(bool) + flex_start = optional(bool) workload_metadata_config_mode = optional(string) }) default = {}