diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 163a96a55b..34e61cd6c8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/antonbabenko/pre-commit-terraform - rev: v1.97.0 + rev: v1.99.0 hooks: - id: terraform_fmt - id: terraform_docs diff --git a/CHANGELOG.md b/CHANGELOG.md index 99a3ff8854..e0fb947886 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,13 @@ All notable changes to this project will be documented in this file. +## [20.36.0](https://github.com/terraform-aws-modules/terraform-aws-eks/compare/v20.35.0...v20.36.0) (2025-04-18) + + +### Features + +* Add support for cluster `force_update_version` ([#3345](https://github.com/terraform-aws-modules/terraform-aws-eks/issues/3345)) ([207d73f](https://github.com/terraform-aws-modules/terraform-aws-eks/commit/207d73fbaa5eebe6e98b94e95b83fd0a5a13c307)) + ## [20.35.0](https://github.com/terraform-aws-modules/terraform-aws-eks/compare/v20.34.0...v20.35.0) (2025-03-29) diff --git a/README.md b/README.md index 1d5b5c07be..4a511ae8bf 100644 --- a/README.md +++ b/README.md @@ -318,7 +318,7 @@ We are grateful to the community for contributing bugfixes and improvements! Ple | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | | [time](#requirement\_time) | >= 0.9 | | [tls](#requirement\_tls) | >= 3.0 | @@ -326,7 +326,7 @@ We are grateful to the community for contributing bugfixes and improvements! Ple | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | | [time](#provider\_time) | >= 0.9 | | [tls](#provider\_tls) | >= 3.0 | @@ -404,6 +404,7 @@ We are grateful to the community for contributing bugfixes and improvements! Ple | [cluster\_endpoint\_private\_access](#input\_cluster\_endpoint\_private\_access) | Indicates whether or not the Amazon EKS private API server endpoint is enabled | `bool` | `true` | no | | [cluster\_endpoint\_public\_access](#input\_cluster\_endpoint\_public\_access) | Indicates whether or not the Amazon EKS public API server endpoint is enabled | `bool` | `false` | no | | [cluster\_endpoint\_public\_access\_cidrs](#input\_cluster\_endpoint\_public\_access\_cidrs) | List of CIDR blocks which can access the Amazon EKS public API server endpoint | `list(string)` |
[| no | +| [cluster\_force\_update\_version](#input\_cluster\_force\_update\_version) | Force version update by overriding upgrade-blocking readiness checks when updating a cluster | `bool` | `null` | no | | [cluster\_identity\_providers](#input\_cluster\_identity\_providers) | Map of cluster identity provider configurations to enable for the cluster. Note - this is different/separate from IRSA | `any` | `{}` | no | | [cluster\_ip\_family](#input\_cluster\_ip\_family) | The IP family used to assign Kubernetes pod and service addresses. Valid values are `ipv4` (default) and `ipv6`. You can only specify an IP family when you create a cluster, changing this value will force a new cluster to be created | `string` | `"ipv4"` | no | | [cluster\_name](#input\_cluster\_name) | Name of the EKS cluster | `string` | `""` | no | diff --git a/examples/eks-auto-mode/README.md b/examples/eks-auto-mode/README.md index b2549472e9..fa7d8fc227 100644 --- a/examples/eks-auto-mode/README.md +++ b/examples/eks-auto-mode/README.md @@ -25,13 +25,13 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/examples/eks-auto-mode/versions.tf b/examples/eks-auto-mode/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/examples/eks-auto-mode/versions.tf +++ b/examples/eks-auto-mode/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/examples/eks-hybrid-nodes/README.md b/examples/eks-hybrid-nodes/README.md index 9f1a602f58..c092a8f450 100644 --- a/examples/eks-hybrid-nodes/README.md +++ b/examples/eks-hybrid-nodes/README.md @@ -26,7 +26,7 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | | [helm](#requirement\_helm) | >= 2.16 | | [http](#requirement\_http) | >= 3.4 | | [local](#requirement\_local) | >= 2.5 | @@ -36,8 +36,8 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | -| [aws.remote](#provider\_aws.remote) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | +| [aws.remote](#provider\_aws.remote) | >= 5.95 | | [helm](#provider\_helm) | >= 2.16 | | [http](#provider\_http) | >= 3.4 | | [local](#provider\_local) | >= 2.5 | diff --git a/examples/eks-hybrid-nodes/versions.tf b/examples/eks-hybrid-nodes/versions.tf index 124db32301..f392d1edb8 100644 --- a/examples/eks-hybrid-nodes/versions.tf +++ b/examples/eks-hybrid-nodes/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } helm = { source = "hashicorp/helm" diff --git a/examples/eks-managed-node-group/eks-al2023.tf b/examples/eks-managed-node-group/eks-al2023.tf index 349da821f9..8fe34c62c2 100644 --- a/examples/eks-managed-node-group/eks-al2023.tf +++ b/examples/eks-managed-node-group/eks-al2023.tf @@ -20,6 +20,7 @@ module "eks_al2023" { example = { # Starting on 1.30, AL2023 is the default AMI type for EKS managed node groups instance_types = ["m6i.large"] + ami_type = "AL2023_x86_64_STANDARD" min_size = 2 max_size = 5 diff --git a/examples/eks-managed-node-group/versions.tf b/examples/eks-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/examples/eks-managed-node-group/versions.tf +++ b/examples/eks-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/examples/karpenter/README.md b/examples/karpenter/README.md index f9eef90469..381d32f98e 100644 --- a/examples/karpenter/README.md +++ b/examples/karpenter/README.md @@ -94,15 +94,15 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | | [helm](#requirement\_helm) | >= 2.7 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | -| [aws.virginia](#provider\_aws.virginia) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | +| [aws.virginia](#provider\_aws.virginia) | >= 5.95 | | [helm](#provider\_helm) | >= 2.7 | ## Modules diff --git a/examples/karpenter/versions.tf b/examples/karpenter/versions.tf index fa41a8a35f..6a1b47cbd3 100644 --- a/examples/karpenter/versions.tf +++ b/examples/karpenter/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } helm = { source = "hashicorp/helm" diff --git a/examples/self-managed-node-group/versions.tf b/examples/self-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/examples/self-managed-node-group/versions.tf +++ b/examples/self-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/main.tf b/main.tf index 18933422f5..c10d79608d 100644 --- a/main.tf +++ b/main.tf @@ -40,6 +40,7 @@ resource "aws_eks_cluster" "this" { version = var.cluster_version enabled_cluster_log_types = var.cluster_enabled_log_types bootstrap_self_managed_addons = local.auto_mode_enabled ? coalesce(var.bootstrap_self_managed_addons, false) : var.bootstrap_self_managed_addons + force_update_version = var.cluster_force_update_version access_config { authentication_mode = var.authentication_mode diff --git a/modules/eks-managed-node-group/README.md b/modules/eks-managed-node-group/README.md index 24e3e9f678..b658c64421 100644 --- a/modules/eks-managed-node-group/README.md +++ b/modules/eks-managed-node-group/README.md @@ -64,13 +64,13 @@ module "eks_managed_node_group" { | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/modules/eks-managed-node-group/versions.tf b/modules/eks-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/modules/eks-managed-node-group/versions.tf +++ b/modules/eks-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/modules/fargate-profile/README.md b/modules/fargate-profile/README.md index b636fbe386..d6ab4ed144 100644 --- a/modules/fargate-profile/README.md +++ b/modules/fargate-profile/README.md @@ -29,13 +29,13 @@ module "fargate_profile" { | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/modules/fargate-profile/versions.tf b/modules/fargate-profile/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/modules/fargate-profile/versions.tf +++ b/modules/fargate-profile/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/modules/hybrid-node-role/README.md b/modules/hybrid-node-role/README.md index 4076fc35f5..50c5a05ec7 100644 --- a/modules/hybrid-node-role/README.md +++ b/modules/hybrid-node-role/README.md @@ -75,13 +75,13 @@ module "eks_hybrid_node_role" { | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/modules/hybrid-node-role/versions.tf b/modules/hybrid-node-role/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/modules/hybrid-node-role/versions.tf +++ b/modules/hybrid-node-role/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/modules/karpenter/README.md b/modules/karpenter/README.md index fe1956eb80..4523024f79 100644 --- a/modules/karpenter/README.md +++ b/modules/karpenter/README.md @@ -86,13 +86,13 @@ module "karpenter" { | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/modules/karpenter/versions.tf b/modules/karpenter/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/modules/karpenter/versions.tf +++ b/modules/karpenter/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/modules/self-managed-node-group/README.md b/modules/self-managed-node-group/README.md index 9fe09d0998..fd6f97ad5e 100644 --- a/modules/self-managed-node-group/README.md +++ b/modules/self-managed-node-group/README.md @@ -43,13 +43,13 @@ module "self_managed_node_group" { | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/modules/self-managed-node-group/versions.tf b/modules/self-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/modules/self-managed-node-group/versions.tf +++ b/modules/self-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/tests/eks-fargate-profile/README.md b/tests/eks-fargate-profile/README.md index 7bb85d63f7..7eeb8a8326 100644 --- a/tests/eks-fargate-profile/README.md +++ b/tests/eks-fargate-profile/README.md @@ -18,13 +18,13 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/tests/eks-fargate-profile/versions.tf b/tests/eks-fargate-profile/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/tests/eks-fargate-profile/versions.tf +++ b/tests/eks-fargate-profile/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/tests/eks-hybrid-nodes/README.md b/tests/eks-hybrid-nodes/README.md index 8f2ac1206c..5c1a427876 100644 --- a/tests/eks-hybrid-nodes/README.md +++ b/tests/eks-hybrid-nodes/README.md @@ -18,7 +18,7 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | | [tls](#requirement\_tls) | >= 4.0 | ## Providers diff --git a/tests/eks-hybrid-nodes/versions.tf b/tests/eks-hybrid-nodes/versions.tf index 37eb431fb9..afcb64ae1a 100644 --- a/tests/eks-hybrid-nodes/versions.tf +++ b/tests/eks-hybrid-nodes/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } tls = { source = "hashicorp/tls" diff --git a/tests/eks-managed-node-group/README.md b/tests/eks-managed-node-group/README.md index 91fc990a92..4fd29eb844 100644 --- a/tests/eks-managed-node-group/README.md +++ b/tests/eks-managed-node-group/README.md @@ -18,13 +18,13 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/tests/eks-managed-node-group/versions.tf b/tests/eks-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/tests/eks-managed-node-group/versions.tf +++ b/tests/eks-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/tests/fast-addons/README.md b/tests/fast-addons/README.md index 5c27596125..e2fab2dfa9 100644 --- a/tests/fast-addons/README.md +++ b/tests/fast-addons/README.md @@ -22,13 +22,13 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/tests/fast-addons/versions.tf b/tests/fast-addons/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/tests/fast-addons/versions.tf +++ b/tests/fast-addons/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/tests/self-managed-node-group/README.md b/tests/self-managed-node-group/README.md index 7a30923161..437ad94e3d 100644 --- a/tests/self-managed-node-group/README.md +++ b/tests/self-managed-node-group/README.md @@ -18,13 +18,13 @@ Note that this example may create resources which cost money. Run `terraform des | Name | Version | |------|---------| | [terraform](#requirement\_terraform) | >= 1.3.2 | -| [aws](#requirement\_aws) | >= 5.83 | +| [aws](#requirement\_aws) | >= 5.95 | ## Providers | Name | Version | |------|---------| -| [aws](#provider\_aws) | >= 5.83 | +| [aws](#provider\_aws) | >= 5.95 | ## Modules diff --git a/tests/self-managed-node-group/versions.tf b/tests/self-managed-node-group/versions.tf index 4736a5b5f7..c62bcdb38e 100644 --- a/tests/self-managed-node-group/versions.tf +++ b/tests/self-managed-node-group/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } } } diff --git a/variables.tf b/variables.tf index 855c2133ec..b4881b2988 100644 --- a/variables.tf +++ b/variables.tf @@ -38,6 +38,12 @@ variable "cluster_enabled_log_types" { default = ["audit", "api", "authenticator"] } +variable "cluster_force_update_version" { + description = "Force version update by overriding upgrade-blocking readiness checks when updating a cluster" + type = bool + default = null +} + variable "authentication_mode" { description = "The authentication mode for the cluster. Valid values are `CONFIG_MAP`, `API` or `API_AND_CONFIG_MAP`" type = string diff --git a/versions.tf b/versions.tf index 4466790686..0ce85c882e 100644 --- a/versions.tf +++ b/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.83" + version = ">= 5.95" } tls = { source = "hashicorp/tls"
"0.0.0.0/0"
]