This repository contains Terraform configurations to provision an Amazon EKS (Elastic Kubernetes Service) cluster on AWS.
Before you begin, ensure you have the following prerequisites:
- Terraform installed on your local machine.
- AWS IAM credentials configured with appropriate permissions.
kubectl
installed on your local machine to interact with the Kubernetes cluster.
-
Clone this repository:
git clone https://github.com/NahlaAbdAlghany/EKS-Cluster-Using-Terraform.git cd EKS-Cluster-Using-Terraform
-
Initialize Terraform:
terraform init
-
Modify the
variables.tf
file to set your desired configuration options. -
Review and apply the Terraform plan:
terraform plan terraform apply
-
Once the cluster is provisioned, configure
kubectl
to connect to the cluster:aws eks --region us-east-1 update-kubeconfig --name demo
-
Verify the cluster connectivity:
kubectl get nodes
Find the deployment YAML file here to deploy resources onto the EKS cluster.
To clean up and delete all resources provisioned by Terraform, run:
terraform destroy