How to Deploy To Kubernetes with Jenkins GitOps GitHub Pipeline - Tutorial + Real World Demo
HTML-код
- Опубликовано: 4 авг 2024
- Create Real World CI CD Pipeline using Jenkins and GitOps (ArgoCD) to dockerize your code, and deploy the container into a Kubernetes cluster.
🔥 Get my courses with max discount (Limited Time): bit.ly/3Eku9RH
👍 Subscribe for more tutorials like this: bit.ly/2Yk0Kbb
👨🎓 Installation instruction links, codes and notes : github.com/saha-rajdeep/kuber...
⭐️ Want to connect with me?
🤳 Instagram: / cloudwithraj
🏢 LinkedIN: / cloudwithraj
🐦Twitter: / cloudwithraj
🖼 Facebook: / cloudwithraj
Timestamps:
00:00 Agenda
01:18 GitOps Workflow
06:31 Jenkinsfile and Dockerfile
12:36 Jenkins Installation and Credentials Setup
16:29 Create Jenkins Jobs
20:22 ArgoCD(GitOps) Installation
22:40 ArgoCD(GitOps) Setup
25:29 GitHub Webhook Setup
26:28 Fully Automated Pipeline - Наука
If you found this video useful, please click the "Like" button. RUclips sends the video to new viewers with more Likes. Ty so much for helping this channel grow 🙏
Hi Raj,
where is your kubernetesmanifest repo?
Have you delete it?
@@ninghan778 github.com/saha-rajdeep/kubernetesmanifest
@@cloudwithraj Please create video for Git & Jenkins with AWS EKS. I am trying to implement Ci/CD for EMR on EKS.
That's the best video, by far, I have ever seen about Jenkins... I was buying courses, clicking around RUclips, etc. - and I am so glad I finally found this one.
All the other ones were very theoretically, or with just a "hello world" output, but no added value for me as a developer who wants to automate building & deployments.
Thanks so much for your content!
Glad it was helpful!
Brilliant tutorial Raj... I am now watching your video first on any topics I search !!
Been trying to bring all the theory together and apply it for weeks now, this video helped me do exactly that. Thank you!
Excellent! Glad to know this was useful Gabriel!
All hail the real Cloud Guru! Thank you so much Raj! 🙏🏽😊
Ty santosh bhai
I would say that this was the best of best video I watched for the whole CI/CD pipeline flow. Recommended and shared to my circle. Thanks Raj
It's a fantastic video to understand and the entire pipe line.
Thank you so much Raj, this video helps me alot with CD. cheers from Chile.
Great video. Thank you. I am about to give up jenkins for new generation tools. But you have brought me back. Jenkins is really still awesome tool for devops.
Yes, Jenkins is still the most popular DevOps tool. Glad my video helped
Clear and Concise.. Keep'em coming
Ty Sonam
Excellent video. Very descriptive and very simple explanation. Thanks so much!!!.
Glad you enjoyed it!
Dada. Darun!! Khub helpful video. Onek onek dhonyobad!
Awesome video....truely full of knowledge
Sir, Learning Latest TOP Technology are simplified which is easy to learn. Great service.
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
This is amazing raj!
Amazing sir thanks for bringing this real time demos here and making things easy to learn and getting familiar
Glad you liked it Anand!
Very interesting video to know more about Gitops
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Thanks for all your work 👌🏻
Thanks for watching Magnus
This is amazing. Thank you so much!
Glad it was helpful!
This video is very cool!
amazing am still speechless with qualify of delivery here , thanks
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Very Nice Explanation. Super Helpful.
Glad it was helpful!
Excellent explanation very helpful .. watching this video gave me lots of confidence about the road map 😊😊
Glad it was helpful!
Thanks Rajdeep da. Finally understood the gist of gitops.
Dhonyobad Bibek bhai
Very useful video! Keep it up
Such good content
nice tutorial!! thanks Raj
Most welcome!
Great video..thankyou
Greats for beginers!
Great video and very detailed :)
Glad it helped!
This is amazing!!! Thanks sir✌
Most welcome 😊
Awesome demo Raj.
Thanks Tekena, glad it was helpful!
Quite content sir! Thank you
Most welcome!
hi raj . really wonderful video.. thanks !!
Most welcome!
Nice explanation! Thx!
Glad it was helpful!
awesome thanks 🙏
thank you Raj.
Awesome tutorial
Ty Vignesh
Waiting for this video
Thanks for watching 🙏🙏
Good one Raj!!! It would be great if you can cover the final piece which is hosting the website for internet!!!
Extremely helpful, thank a lot! I have subscribed and liked as it is deserve. In additional will be good to know hot to deploy application with several deployments to different namespaces.
Thanks for the sub!
gracias por compartir
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Thank you so much for this video. It helped me a lot to revolve a misunderstanding about the deployment image tagging. For some reason, I was stuck thinking that "latest" image tag should be the best strategy in my deployments, but I understood that I was wrong.
Glad it was helpful!
very good content, thx so much
Glad you enjoyed it
Thanks for the amazing video!
I have a question.
Before merging the pull requests can we see the diff? Like what resources will get created in the cluster once the PR is merged to the main branch?
Can we use argocd diff on pull requests?
Thanks
Great Lecture..
Glad it was helpful!
Thanks for the great video.
Commenting as a reply because I posted a question earlier and it is not appearing. Asking here again.
First of all thanks for the awesome video.
In ArgoCD setup, in source we haven't mentioned anything about deployment file. Does it automatically pick *.yaml?
Hey Sameer, ArgoCD automatically picks up YAML files from the repo, you don't need to configure anything.
cool!)
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Though Jenkins part was a bit confusing for a beginner, but the whole workflow 🔥 awesome.
liked the content, very impressive :)
Much appreciated!
Awsum
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Thanks a lot!
You're welcome!
Subscribed sir
Thanks for putting this great and helpful video together. Learnt a whole lot from you! You earned a new subscriber 🙂
Thanks for the sub!
thanks raj this video is really very helpful, can u suggest which ome should i prefer in my organization FLUX or ARGO CD ??and why
Hi Raj when I tried to deploy the app with argoCd (windows machine ) I got
Traceback (most recent call last):
File "/usr/local/lib/python3.8/runpy.py", line 185, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "/usr/local/lib/python3.8/runpy.py", line 144, in _get_module_details even If I want to run with docker I got the same issue Do you have any idea
Hey Raj, Thanks for the great content and knowledge sharing🙏 One request from my side please create a video on Azure Devops pipeline if possible in future. Thanks a lot for sharing knowledge.... 👍👍
Thanks Sharath. I will keep this in mind for future videos.
Nice video, probably you may be planning to make one on MLOps as well.
Maybe in the future Maneesh!
Thanks Rajdeep, Great video! I want to become DevOps but I generality missed hands on exercises I I would like to build this as a playground learning path could you give me approximately what will be the price in Amazon for 6 hours to set of this pipeline? Thank you very much in advance. I consider buying some of your products in near future defiantly !
It's really cool stuff. I have a question.
In this entire process where is the scope for Sanity/Regression test suites ...?
Thanks Raj your video are always helpful and knowledgeable about latest technology.
Can you please make a video on how to setup Argo CD in GKE Autopilot Kubernetes cluster
Will try
Thanks for sharing valuable information,
I have one question how to enable the Argocd in kubespray cluster
Hi Rag, great tutorial, am stuck at the port forwarding part in the argocd installation in other to access my argocd server ui in my browser. am geting getting connection refused. what do i do, everything is properly set up
do you have tutorial for the traditional? i need to deploy image to the kubernetes without the gitops part
Hello, Raj.
Thank you very much for content and tutorial.
I got stuck while trying to create app in argocd. When I click "Create" I got error : "Unable to create application: permission denied".
Could you, please, share advise.
Hello Sir, This video really help me. I just want to know buildImage steps
Hi Sir, your each and every video very informative and me learn a lot from your video, it will be great if you publish blockchain video , and how we can use AWS blockchain service to make blockchain infrastructure..
Great suggestion!
cant we install argocd on ec2 instance itself
thank you for useful lesson. may I ask in wich step you have installed kubernetes cluster ??
I created cluster using "eksctl create cluster" command
Hi Rag, Nice Video, pls am still unable to access the argocd ui after running the port forwarding command. When I type localhost:8080 in my browser, I get connection refused, its timing out, what might be the problem, I have been stuck here forever. Pls help?
Thanks for this nice video. Do you have any video for same use case using AWS code build and code pipeline via cloud formation template ?
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Hey Raj, amazing explanation, I have a small question here, you were explaining here about when source code gets build and turns into an image and therefore jenkins updates the deployment manifest file with new image tag, So how about other changes in configuration manifests, secrets etc ... How ArgoCD deal with it, could you please explain ?
Hey Varun, anytime anything changes in the manifest file (not just container image name), ArgoCD will deploy the manifest into the kubernetes cluster.
Great video. I have learnt so much. I'm continously learning kubernetes. I want to ask you mentioned about installing docker and github on an ec2 instance. Would that be installed on a separate ec2 instance or on a jenkins instance ec2? Anyone please feel free to help answer.
You can install everything in a same EC2 instance but you need to choose machine family like t2.large or t3.small and more over see the billing charges as well for 1 hour how the AWS is charging depending the machine family you choose. Terminate the instances once your done else you will be billed.
Hi Raj...thank you very much such a informative video.... i have one question.. is there any way to store crdedentials of Docker, ECR, aws-accesskey...etc. externally and call them in to jenkis pipeline... (for example aws-KMS...Hashicorp key-vault..)
yes you can do that, there are a variety of plugins that will do so. check those out! Vault would be a good one,
@Raj you mentioned Disadvantge of traditional Devops system is "if Some one deleteting the Deployments" what does autoscaling of pods or deployments will do here ?
If someone deletes the deployment from Kubernetes, with NON GitOps the autoscaling is also gone (since it's part of the deployment yaml). But with GitOps doesn't matter what you delete in cluster, it'll automatically reconcile with Git and provision all those back.
In jenkins, my pipeline was failing due to some packages need to update. Does I need to separately install all the required packages in jenkins? I installed jenkins on local using docker
Your pipeline will fail locally because we need an actual address to access. he specifies this in the video. GL
What did you use for the slides animation? Great video
I use Adobe After Effects and Premiere Pro with regular slides. Glad you like it!
in this scenario did you have Kubernetes running on Ec2 or as EKS ?
As EKS, but will work on self managed kubernetes or GKE or AKS as well.
Hello Raj , i have a question. From where the argoCD collecting the latest docker image? Is it from the server or from dockerhub.
You mean for the application? It just runs the deployment manifest file. In deployment manifest it is fetching from Dockerhub, hence it will get from Dockerhub.
@@cloudwithraj okay understood.... But how it's getting from dockerhub? Where you have integrated argoCD with it?
It is not argocd which will contact docker hub , but your kubernetes cluster . Argocd will only get deployment yaml and deploy it
Hi, it's amazing video, but i have a question here why you are used Docker hub?
Just to make it easy to understand and follow. Same flow will work with ECR but docker hub is the most common registry known to everyone
Hello Raj, I am gettign this error while implementing the udemy version of the video "+ git commit -m Done by Jenkins Job changemanifest: 4
HEAD detached at a6b1eb8
nothing to commit, working tree clean" any clues on how I can solve the problem
your git configuration is messed up.
Hi Sir, do you have aws cloudmap(service discovery) tutorials?
Don't have any cloudmap tutorials yet
Sir, If i want to revert github commit in this scenerio, how to do this. please help
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Please sir can clear my confusion cloud computing or data analyst which is better career?
Depends on what's your background is. What are you studying/working on currently?
@@cloudwithraj Currently I am working as design engineer (mechanical).
I wanted to move IT industry I am confusioned could please suggest me which better career....
Hi, at the end why are we deleting the pods instead of updating the existing one with new changes.
Hey Kartik, that's how Kubernetes works. It does a rolling deployment because a pods is immutable. It will spin up new pod and then terminate old pod to ensure the application is up and running.
@@cloudwithraj Thankyou so much.
May you pls share link for video on Jenkins auto build/deployment using Ansible and GiT
unable to deply on local machine
sir can we use and install argocd in amazon ec2 ??
It is installing it in EC2 worker node for the Kubernetes cluster. Do you mean vanilla EC2, without K8s?
@@cloudwithraj yes sir because in the demo we can see that we have accessed the argocd in localhost.
Nice tutorial but it was even better if you could use Helm
why we need argo in this pipeline can someone explain thanx
argo takes the code from github and compares it to whats currently running in kubernetes, if the state is different it will deploy the new state.
@@Chimperly thanks mate 🙏
Hello, where did you install argocd??
Bro, at timestamp 20:33
@@cloudwithraj Sorry maybe I didn't explain it in the best way I mean did you install argocd in your localhost ?
Argocd is installed in the Kubernetes cluster he created
Hi Rajdeep,
Greetings for the day!!
I saw your youtube video for GitOps. It is really Super. I was trying to replicate in my local, but the image flask you used in demo is giving me ImagePullBackOff and CrashLoopBackOff. when I do kubectl get pods.Need your help in this.
Thanks and regards,Rakhi
hey, im getting this error too, did you resolve this ?
I hope your next video course (Udemy) can be something similar to this video: sit a a regular developer, start with a empty project (C#, Django, Go, whatever different than Springboot), git push changes to DEV branch, run test that fails, run test that passes, require approval when pushing to Production branch. That´s what I need. Thank you!
Great suggestion Geraldo! I will definitely keep this in mind
Add Helm instead of deployment.yaml
container gets created but then keeps restarting afterwards
Fixed requirements.txt. Jinja support was dropped in Flask 1.1 version (Sneaky of them!), updated Flask version to 2.1. Should work now.
You dont deserve these much subscribers as you didnt put still one complete course and not even practical 😤
Thank you for your comment. Be sure to contact the Telegrm line above for more information and consultation on BTC//ETH investment. I have a new investment I am sure you will like to be part of.......
Hello Raj im having issues deploying my images. i keep getting "crashloopback errors in argocd" and this "ImportError: cannot import name 'escape' from 'jinja2' (/usr/local/lib/python3.8/site-packages/jinja2/__init__.py)" when i do kubectl logs -f podname
Fixed requirements.txt. Jinja support was dropped in Flask 1.1 version (Sneaky of them!), updated Flask version to 2.1. Should work now.
@@cloudwithraj Awseome. But tbh I didn’t understand the flask part. Do I have to install it in my eks cluster or ?
Raj could you comment on this error. keep getting "crashloopback errors in argocd" and this "ImportError: cannot import name 'escape' from 'jinja2' (/usr/local/lib/python3.8/site-packages/jinja2/__init__.py)"
Fixed requirements.txt. Jinja support was dropped in Flask 1.1 version (Sneaky of them!), updated Flask version to 2.1. Should work now.
@@cloudwithraj Thank you Raj. You are Batman of cloud world! :)
I am facing an issue with my build.
+ docker build -t mkhan1976/test .
/var/jenkins_home/workspace/demo2@tmp/durable-f14bcf88/script.sh: 1: docker: not found
ERROR: script returned exit code 127
did you fix it? I was like that too. How do you fix it?