How to Create EKS Cluster Using Terraform + IAM Roles for Service Accounts & EKS Cluster Autoscaler



In this video, we will create an EKS cluster using Terraform.

☕ – Buy me a coffee: https://www.buymeacoffee.com/antonputra
🤝 – Add me on LinkedIn: https://www.linkedin.com/in/anton-putra

=========
⏱️TIMESTAMPS⏱️
0:00 Intro
1:06 Create AWS VPC Using Terraform
1:24 Create Internet Gateway AWS Using Terraform
1:34 Create Private and Public Subnets in AWS Using Terraform
3:24 Create NAT Gateway in AWS Using Terraform
4:09 Create EKS Cluster Using Terraform
7:09 Create IAM OIDC Provider EKS Using Terraform
10:17 Create Public Load Balancer on EKS
12:01 Create Private Load Balancer on EKS
13:01 Deploy EKS Cluster Autoscaler
15:08 EKS Cluster Auto Scaling Demo

=========
Source Code
📚 – Tutorial: https://antonputra.com/terraform/how-to-create-eks-cluster-using-terraform/
🆘 – Support Channel: https://github.com/sponsors/antonputra

=========
SOCIAL
📚 – Tutorials: https://antonputra.com
🎙 – Twitter: https://twitter.com/antonvputra
📨 – Email: me@antonputra.com
🎮 – Discord: https://discord.gg/Wy5SPDSTjX

#Terraform #EKS #Kubernetes

source

26 thoughts on “How to Create EKS Cluster Using Terraform + IAM Roles for Service Accounts & EKS Cluster Autoscaler”
  1. How do you tackle the situation when the cluster autoscaler has changed the cluster scaling from 1 to 2 (and terraform won't know this) and then you need to perform a terraform deployment? In that case the scaling config will show the desired size of the cluster node has been changed and will try to put it back to 1, isn't it?

  2. Hi Anton, I am getting errror "

    │ Inappropriate value for attribute "route": element 0: attribute "core_network_arn" is required." in route tables creation.

  3. Good Video guy.

    One question, on managedNodes using eksctl is recommended install the node termination handler or eksctl manges this by default for us ?.

  4. hello! thank u v much this is v informational.
    was wondering how to limit public network access through inbound rules/security groups like an ec2 – currently the loadbalancer is accessible anywhere

  5. Great Video Anton! For-Self Managed K8S clusters using EKS but using " worker-groups" as worker nodes with Auto-Scaling, will the same policies you attached to your IAM role be the same? Looking forward to more great stuff from you!

  6. Great tutorial! Thanks for the video. I'm curious why there is no security groups in the terraform files?

  7. Why do we use cluster autoscaler as deployment if we already have node autoscaling in the nodes.tf file ?
    I mean this one:

    resource "aws_eks_node_group" "private-nodes" {

    cluster_name = aws_eks_cluster.demo.name

    node_group_name = "private-nodes"

    node_role_arn = aws_iam_role.nodes.arn

    subnet_ids = [

    aws_subnet.private-us-east-1a.id,

    aws_subnet.private-us-east-1b.id

    ]

    capacity_type = "ON_DEMAND"

    instance_types = ["t3.small"]

    scaling_config {

    desired_size = 2

    max_size = 5

    min_size = 2

    }

    update_config {

    max_unavailable = 1

    }

  8. Thank you very much for the video Anton. It was really awesome and helpful. How can we setup the aws load balancer controller for eks ingress via Terraform?

  9. Awesome video. I have been automated my deployment EKS using terraform since I watch your video it make me to practice it. I have question is the terraform can execute a script since I'm using rancher inside the kubernetes for manage my Kubernetes using EKS.

  10. Скажи, а у тебя было время посмотреть в сторону Karpenter? я вот глянул, крутая штука, вроде бы.

Leave a Reply

Your email address will not be published.

Captcha loading...