This repository contains terraform code that provisions AWS EKS cluster with EKS managed node group and access to the internet (public) and a "classic" LB. Can be Optionally built automatically with github actions with a push command to branch "main". in addition, has a terraform destroy ability if a commit is pushed to branch "destroy" a pipeline condition will be triggered and run "terraform destroy"
- AWS cli configured
- Github repositroy access
- Kubernetes with kubectl installed
- Clone main repository
git clone [email protected]:alonwillmakeit/Devops-Infra-Final.git && cd Devops-Infra-Final && echo "Generic commit to trigger CI" > genericfiletorunCI.txt
- Run
git add . && git commit -m "commit to trigger CI" && git push
- Run
aws eks --region us-east-1 update-kubeconfig --name demo
- Apply your manifests into the cluster
kubectl apply -f k8s/deployment.yaml && kubectl apply -f k8s/service.yaml
- Might need to wait 1-2 minutes of LB to fully registers and run
kubectl get svc | awk '/counter-service/ {print $4}'
If you still don't still a AWS URL, the LB still didn't finish proccessing, when you do see the URL, u can access it and access our application!
Now we have created an EKS cluster with our application deployed on , that can be accessed throught the link received in step 3 in K8S application