Terraform code to install create EKS cluster using NodeGroup and install Consul on same.
- AWS Account.
- aws-cli/
- kubectl >= 1.21/
- helm >= 3.0/
- Understanding of K8s, Helm, and Terraform CLI.
-
git clone https://github.com/SuyashHashiCorp/consul-aws-eks-terraform.git cd consul-aws-eks-terraform
-
Update the values as per the below table in variables.tf file -
You can update the value of values.yaml as per your requirement. You can find the sample under "templates" folder of this repo.
To provision the cluster, execute the following commands.
terraform init
terraform plan
terraform apply
- Config kubectl to talk to your EKS cluster
aws eks update-kubeconfig --region <region where you deployed your cluster> --name <your cluster name>
- Run the below to verify you are connected to your Kubernetes cluster
kubectl cluster-info
terraform destroy -auto-approve
terraform apply -auto-approve