Setup EKS Cluster using eksctl and Deploy Springboot Microservices into EKS using Jenkins Pipeline
Вставка
- Опубліковано 11 вер 2024
- www.coachdevop...
We will learn how to automate springboot microservices builds using Jenkins pipeline and Deploy into AWS EKS Cluster with help of Kubernetes CLI plug-in.
We will use Springboot Microservices based Java application. I have already created a repo with source code + Dockerfile. The repo also have Jenkinsfile for automating the following:
- Automating builds using Jenkins
- Automating Docker image creation
- Automating Docker image upload into AWS ECR
- Automating Deployments to Kubernetes Cluster
EKS cluster can be created by following steps below:
www.coachdevop...
Beautiful Presentation with Beautiful English with no reflection of South languages .
Thank you!
Man I wanna give lots of thanks to u , very well explained in simplest way. I saw many videos but this one was game changer i understood the whole CI-CD flow thanks alot
Akshay, You're welcome!
Salute, Perfect video for EKS. I saw so many videos, but here I found out roadmap, how, why and what we are doing, explanations. thanks DevOps coach.
Glad it helped! Hope you have subscribed to my channel.
@@DevOpsCoach I have 1 confusion here in this tutorial. When you first run the create cluster command(eksctl create cluster --nodes 2) it creates 2 worker nodes, After that when eks-deploy-k8.yaml file is applied it shows 2 pods created and 2 deployments created with 1 SVC. So does these 2 deployments occurred on that 2 worker nodes(1 on each worker node) ? and where it shows pods=2, is these 2 pods belong to any 1 worker node? Please explain me, I am confused here or missing something.
What a, person you r.. And awesome patience to cover this video.. You r the superb
Thank you so much, Uday
I can't express my happiness. I was waiting for such video for 3 months.
Thank you so much sir.
So nice of you
Great job! Well explained. One of the best videos of showcasing a lot of moving parts of CI/CD with latest technologies like Kubernetes
Glad it was helpful, thank you for your kind words!
all topics consolidated -good one- one stop shop for all devops needs.
Thank you 🙏
I love you man. Thank you for the Clear cut explanation of everything.
You welcome Sravan
Excellent... Well explained everything in a single flow.. Content is next level..
Awesome, thank you Sujay.
Awesome!! Worked just like that without any errors or issues. Very detailed one!
Good to know, thank you so much
Man, take a bow. Your explanation made it so easy. Trust me this was my first video on EKS cluster setup & application deployment. Would like to see more contents around Terraform & EKS. Thanks a lot.
Great to hear! Thanks Aastha!!!
Great Explanation. Thanks a lot.
Glad it was helpful! thank you!
This video has great detailed explanation, Thank you...😇
Glad it was helpful!
Just wow, awesome explanation. 🙏🙏
Glad it was helpful! Thank you
This is very useful and helpful to get Job as i am more senior and new to this platform. Thank you friend and you did a great effort.. - John Trichy
You are very welcome, So glad to hear! Wish you all the best for your new job!
u r the gem on youtube.
Thank you so much, glad it helped you
Sir you are awsome. Thank you so much for making this video. Learned a lot.
You are most welcome
You're an amazing teacher!!
Wow, thank you!
Where can we find info about your training? How long? Price? Content? And all.
@@vback4238 www.coachdevops.com/2023/06/devops-bootcamp-by-coach-ak-on-aws.html?m=1
Great VDO!, Thanks keep going bro
Glad you liked it
Give this man a Medal
glad to help you to learn more!
Thank you very much for sharing this awesome video!
Glad you enjoyed it!
great job sir, you are amazing
Thank you! Cheers!
Hii...I like the way of your explanation, which is simplest and clear to understand everyone. even though our course trainer charged the fees and didn't explained like this..thank you so much
thanks a lot Krishna for your kind words! appreciate your feedback!
No Words Sir, Really great.
Awesome, thank you so much Jash!
This is an awesome video, I cant express how important it was for me now. Thank u for such a work.
You're so welcome!
Great!!! Very Good and valuable vedio you made. Awesome..Thank you so much..
You are most welcome
Thanks for the good explanation.
You welcome 🙏
Superb video
Thank you so much, glad you liked it
Nice tutorial. Awesome explantion.
Thank you so much
sir not a single minute of the video bored me. I am so happy that I learnt so much in just
So nice of you, thank you for the kind words!
amazing man , that was awesome
Thanks a ton!
awesome thanks well explained
Glad it was helpful!
Thanks a lot sir, really informative content!!
Glad you liked it..
Excellent bro.. awesome explanation
Glad you liked it, thank you!
wow explanation 👏point to point 😊
Glad you liked it
@@DevOpsCoach likewise are you going to tell about helm also ?
yes, please check here updated helm playlist. ua-cam.com/video/3FoGwq8eXAY/v-deo.html
@@DevOpsCoach thank you
Thank you so much
You're most welcome
this is super helpful, thank you sir.
You're very welcome!
One of the best explanation for real time scenario, it helped me a lot to understand the flow and how it works. I have a question regarding Pipeline setup , if we follow same cluster setup for dev , uat and prod.. do we need to follow same pipeline steps for prod cluster as well ?
yes absolutely..
Really an awesome video sir. Thank you very much
Glad you liked it
how I say thanks to you I am not understanding because the way you are teaching excellent , amazing. keep it up
excepting some more video on k8s using kops method
thank you so much, keep watching the channel for more videos
Good content 💥 only replacing latest image name in deployment file for next deployment is missing.
Hello Sir, I really thank you for making this valuable video, i request you to make one more session for Continuous Deployment through Bamboo---> AWS EKS ---> AWS Ec2,
this is fantastic. thanks.
You're very welcome!
Sir how about the updating the new image tag inside manifest file before deploying to eks cluster? Do you have video for that?
You made it so simple sir, Ecr is just alternative of docker hub in aws service right?
thanks you.. yes..that is right!
sir i m getting this error
While running it, I got "kubectl: not found". I installed Kubernetes-cli plugin to Jenkins, plese suggest .
You need to install kubectl cli as well in Jenkins
Successfully completed this task sir please share kubernetes same as like each and every point
go and purchase
In k8 yml file do we need to mention load balancer name which we create in AWS !! and at last you are hitting one url to get see your application result, that load balancer url where we can find !! In AWS load balancer section ??
Yes it will create an entry
Hi sir.. Tutorial is awesome, but i had a doubt, in build stage u had given docker.build registry like how it process to build an image from docker file without using docker build -t
That syntax is different. Based on docker pipeline plugin
Ok sir but can you please tell me in a simple way how this fetch image without showing any detail except ecr image, As per docker file spring boot is the image.
I am using the Ubuntu 22 only as we tried to add the command apt-key showing as deprecated
hello sir, i have a issue Kubernetes Deployment successfully, but not displaying the updated content. how to do it please suggest.
you should tag the images with build id dynamically, you should avoid latest tag when building docker image every time
hello sir,can we say that we have deployed our microservice using shescript instead of using argo image updater.?
Hello thank you so much for sharing this amazing tutorial i followed every steps till the end but my pods had imagepullbackoff , i need you're help to resolve this issue , I'm still a newbie i don't know how to go about troubleshooting the problem thank you
@kenzylink - check the deployment.yml file , if the image being referenced is the correct one which is running in your system as well, verify with this command - docker image ls
check your deployment yaml file and make sure image path is right
nice video but the volume is a little bit low.
Noted
my deployment and pods are not getting ready what might be the issue
what is the issue you are having? did you describe your pod using kubectl and find out issue?
thankyou so much ,could you please create same it for eks-farget
yes, I will.
Hello Sir, If we are creating the EKS cluster with terraform, how do we give permissions for kube/config file to jenkins user?
Fantastic training__ Shall we add. Terraform to the work flow please
yes any resources creation in AWS, you can use terraform. please watch this video --> ua-cam.com/video/hyP3RleaQ_o/v-deo.html
Sir Thank you so much for this video. Can you please suggest how can I do monitoring with this lab?
ua-cam.com/video/C38dT0Kt3zs/v-deo.html
@@DevOpsCoach thank you coach 👍
Please provide GitHub link below description
github.com/akannan1087/springboot-app
Hi sir how to do ci-cd for databases in jenkins for sql..Can you please post a video..
Thank you for detailed steps , have a doubt! kubernetes CLI plugin installation is getting failed, May I know alternative plugin to be used? I can see new plugins are available now in jenkins. Please suggest.
you can restart Jenkins. what is the error you are getting?
@@DevOpsCoach Sir, I tried again and it is installed now. I have implemented all the stages successfully but we are not able to view the pods,services info in AWS console . Why is it so? and how to give EKS access to another user now to view pods container info? Please help on this.
Hello Sir, what if ECR instance is private, what are we supposed to do, I mean how to generate a key or password of ECR
it is the same process
could you please create same it for laravel-admin app through this same process
How can We update build number to deploy instead of latest version image.??
stage('Building image') {
steps{
script {
dockerImage = docker.build registry
dockerImage.tag("$BUILD_NUMBER")
}
}
}
where you written dockerfile and create image and how do you took that image
Dockerfile can be written by following documentation..you can build docker image using Dockerfile. docs.docker.com/develop/develop-images/dockerfile_best-practices/
Sir I followed everything correct but at the time of build stage mvn clean install is talking too long, from almost 6 hrs its running, and the instance getting very slow, not able to type any commands in it.
make sure you have good cpu for your ec2 instance. it should be t2.medium or at least 4 GB RAM
As Coach stated, your instance probably has little resources to support the tasks. Change the instance type to medium or large.
Sir I request you to make a video on How to deploy springboot with mysql using jenkins on eks Please sir
Sir please suggest - when i run command after all work - kubectl get pods - I get this error - ImagePullBackOff
use kubectl describe pod command to get error details
you should fork this repo and make changes in eks-deploy-k8s.yaml to pull image from your ECR
Please change image idname in git eks-deploye-k8s.yaml in
@@tradewithshajil7186 yes good way to know
Perhaps pulling image from Coach’s ECR private repo. That won’t work. You need to push the image created into your own ECR and then edit the yaml file with your ECR details prior to deployment.
hello sir
when i do kubectl get pods. The pods still pending
troubleshoot with kubectl describe pod pod_name
Sir will you provide online devops coaching? Please let me know timings and fee
yes, I do. can you please email me? you can get the contact info on this page. www.coachdevops.com/2022/11/aws-azure-cloud-and-devops-coaching.html
Thank you for this content. If I have multiple microservices to deploy to k8s, do I have to create new pipeline for each of them or is there a way to do everything in a single pipeline
usually you create a separate pipeline for each microservice or you can use Helm for deploying multiple microservices into K8S
@@DevOpsCoach You mean I can run helm command if i have it installed from Jenkins script?
here is the video for deploying applications into EKS using helm and Jenkins pipeline --> ua-cam.com/video/Ojb9Rh0BcvA/v-deo.html
Sir, kindly share the github repo URL.. we need to clone this for practice. Thank you !!
check the web page.. it is provided there
Sir, do we have scope to use ansible here to create docker image from jar/war file?
Not really
What type of database your using in this project i didn't get that
it uses default database, H2
Hi bro
Can you do how to deploy application into Ecs
will do
HI can you make a video on how to install Jenkins I have tried many time
but it shows errors
ua-cam.com/video/V1VOrnG93Ew/v-deo.html
please watch this video to know how to install Jenkins
Sir can you please make a GKE video ?
how do you delete the eks cluster on your ec2 ? it won't terminate.
Delete EKS Cluster using eksctl command: sample code below:
eksctl delete cluster --name demo-eks --region us-east-2
or Login to AWS console --> AWS Cloud formation --> delete the stack manually.
you can also delete the cluster under AWS console --> Elastic Kubernetes Service --> Clusters
Click on Delete cluster
Go to your Auto Scaling Group -ASG, and edit your launch configuration by modifying the desired minimum and maximum node capacity to 0. Then go and manually terminate the worker nodes.
Modifying the ASG launch config to zero, will prevent ASG from automatically spinning up new nodes after you terminate your worker nodes.
help jenkins is not showing in my host
can you please give more information?
Why you cannot give us your repo like a guide of the project ?
check the website, repo url is given
@@DevOpsCoach I already saw it . thank u
you welcome
Hii sir,
Can you please share your training session???
Yes, sure, this is the schedule. www.coachdevops.com/2020/08/aws-and-azure-devops-coaching-online.html
can you give us github repo link?
github.com/akannan1087/springboot-app
I strongly regret i bought 5000 rupees course this kind of explanation i did get from it. This question asked in my paytm devops interview 😢 i am not able to answer it
What are you trying to say? Did you get what you were looking for after watching this video?
I getting this error
+ kubectl apply -f pod.yaml
error: error loading config file "/var/lib/jenkins/workspace/jenkinsjob/.kube12416699358756423848config": illegal base64 data at input byte 48
[Pipeline] }
[kubernetes-cli] kubectl configuration cleaned up
[Pipeline] // withKubeConfig
[Pipeline] }
[Pipeline] // script
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
ERROR: script returned exit code 1
Finished: FAILURE
Are you able to query the cluster ? kubectl get nodes command returns anything?
Thank you sooo much
You're welcome!