Capstone project for Udacity Cloud DevOps Nanodegree
This project borrows ideas (and some bash scripts 😉)from courses in the Nanodegree program
- Create an EC2 instance
- Clone this repo because the scripts install needed packages.
- In
templatesdirectory, create CloudFormation stack using:aws cloudformation create-stack --stack-name eks-cluster --region us-west-2 --template-body file://aws-eks-.yml --parameters file://params.json --capabilities CAPABILITY_IAM - Alternatively you can install and use
eksctl, you can use thecluster.yamlby running:eksctl create cluster -f cluster.yaml - When the EKS Cluster is complete, in AWS EKS Dashboard add a Managed Node Group, wait for it to provision.
- Configure EKS cluster with EC2 instance using this command:
Remember the
aws eks update-kubeconfig --name zetaclusterClusterNamevariable in our CloudFormation stack?, its value is what we add there not the--stack-name. - Copy role arn from cloudformation stack outputs into
templates/aws-auth.ymlfile. - Configure
aws-auth.ymlfile in order to attach worker nodes to EKS cluster by running:kubectl apply -f aws-auth.yml - Deploy initial code to Kubernetes cluster and pods using blue deployment in the
deploydirectorykubectl apply -f blue.yml - With
bluedeployment done, you can create the continuous pipeline. - Configure AWS and Docker globally on Jenkins using the
pipeline-awsplugin. If AWS is not configured properly, the pipeline will fail.
- Go to Load balancer in EC2 and select specific load balancer. Copy provided DNS and open it in chrome.
- Alternatively, DNS can also be obtained by typing
kubectl get svcin command line. kubectl get podslet's you see the podskubectl get nodesshow you the nodes
- A notable resource is this question from StackOverflow regarding
pylint.