Skip to main content

What is terraform-aws-eks?

terraform-aws-eks is a Terraform module that creates and manages Amazon EKS (Elastic Kubernetes Service) resources on AWS. Rather than writing dozens of individual resource blocks yourself, you call this module with a handful of variables and it provisions a production-ready EKS cluster along with all the supporting infrastructure it depends on. The module is maintained by the terraform-aws-modules community and published on the Terraform Registry at terraform-aws-modules/eks/aws.

Why use this module?

Provisioning EKS from scratch requires coordinating many AWS resource types — IAM roles and policies, security groups, KMS keys, CloudWatch log groups, OIDC providers, access entries, and the cluster itself. Getting the dependencies between these resources correct, and keeping them up to date as EKS evolves, is time-consuming and error-prone. This module solves that by:
  • Encoding the correct resource relationships and dependency ordering so you don’t have to.
  • Providing sensible, secure defaults (private endpoint enabled, KMS encryption for secrets, IRSA enabled, control-plane audit/api/authenticator logs on by default) while still letting you override everything.
  • Supporting all three EKS compute models — EKS Auto Mode, EKS managed node groups, and self-managed node groups — from a single, consistent interface.
  • Handling cluster access management (access entries) so you don’t need to manage aws-auth ConfigMap manually.

Architecture overview

When you invoke the module, it creates and manages the following AWS resources: The module also includes six sub-modules:

Provider and Terraform requirements

The module requires the following versions, as defined in versions.tf: The TLS and Time providers are declared automatically by the module — you only need to configure the AWS provider in your root module.

Next steps

Quickstart

Deploy your first EKS cluster with EKS Auto Mode in minutes.

EKS Auto Mode

Let AWS manage node lifecycle automatically with built-in node pools.

EKS managed node groups

Provision EC2 worker nodes managed by the EKS service.

Cluster access

Manage Kubernetes API access using EKS access entries.