How to Build and Deploy an app on Kubernetes by GitLab ci cd pipeline

Поделиться
HTML-код
  • Опубликовано: 11 сен 2024
  • CI CD pipeline is used for quick and efficient delivery of an application to its consumers. So, In this "How To" presentation I demonstrate how to create a #gitlab CI/CD #pipeline that uses a #Gitlab-Runner to build and push images to GITLAB #container registry and we will learn how to connect an existing #kubernetes Cluster to GitLab and How to deploy applications on cluster using CI/CD tunnel
    This #tutorial assumes you have a Local Kubernetes cluster like Racher-Desktop . To setup Rancher Cluster on your windows machine, you can follow this tutorial: • How to Install & Confi...
    ==========================================
    www.buymeacoff...
    ==========================================
    Note:
    If you are using GitLab self-managed instance, You need to enable GitLab Kubernetes Agent Server (KAS) from GitLab configuration using below step.
    Add below line in /etc/gitlab/gitlab.rb file
    gitlab_kas['enable'] = true
    Restart or re-configure GitLab.
    All Files related to this Project: (1-K8S-CICD folder)
    github.com/mka...
    How ton install Rancher-Desktop on Windows: • How to Install & Confi...
    #kubernetes #gitlab #gitlab-runner # gitlab # build #deploy #ci cd pipeline #gitlab ci cd tutorial #gitlab tutorial #pipeline #devops ci cd pipeline

Комментарии • 110

  • @Crmzon-do1fe
    @Crmzon-do1fe 3 месяца назад +8

    I've been watching ALOT of devops videos for my job this week, and this is BY FAR the most hands on devops pipeline tutorial I have found. Thank you.

  • @muhammadrehan5722
    @muhammadrehan5722 Месяц назад +1

    The most underrated channel for devops i guess.
    This is all we need i guess simple and clear

  • @Amit007111
    @Amit007111 26 дней назад

    It is very helping to understand the process of web app deployment into kubernative cluster. It is very good devops channel.

  • @AI-4-U
    @AI-4-U 11 месяцев назад +4

    You are the best teacher.
    I took so many courses, but the way you teach goes straight to my head. 🎉🎉🎉🎉

    • @be-devops
      @be-devops  11 месяцев назад

      Thank you, today I started my day with your energetic sentence.

  • @bothorsen4292
    @bothorsen4292 7 месяцев назад +8

    Thank you for this, it was exactly what I needed. If only the gitlab documentation was as good as this video :)

  • @hajermakina7474
    @hajermakina7474 10 месяцев назад +5

    This is such a structured video for those who want to build a complete cicd pipeline. and explanation was really crystal clear ! you are such a gem trainer :) you have really done a fantastic job creating this video, I hope we could get more such end to end project to grind our skills !! Thank you

    • @be-devops
      @be-devops  10 месяцев назад

      You built my day with your full energetic sentences

  • @jameswachira5713
    @jameswachira5713 5 дней назад

    Great tutorial. It has helped me alot. Thank you sir

  • @ssreelakshmi5075
    @ssreelakshmi5075 23 дня назад

    your explanation was good i need some more this type of project videos

  • @DynamiArrow
    @DynamiArrow 3 месяца назад

    Best explanation of this topic that i have seen, great job

  • @amadoudiop6634
    @amadoudiop6634 6 месяцев назад +2

    Excellent tutorial and very well explained. Thank you very much !!!

  • @raph1587
    @raph1587 10 месяцев назад +1

    Wow! This is what I am looking for! Its so detailed and well explained! Keep the Tutorial Videos coming!

  • @feder7582
    @feder7582 2 месяца назад +1

    solid video. would be even greatet with time sections since it offers so much valuable instructions.

  • @jakub6514
    @jakub6514 17 дней назад

    Thank You a lot man for this video

  • @AartiPawar-w7e
    @AartiPawar-w7e 8 дней назад

    great video!

  • @manhnguyenitc
    @manhnguyenitc 4 месяца назад +1

    Thank you very much, it was exactly what I needed :)

  • @naseredinwesleti300
    @naseredinwesleti300 Месяц назад +1

    amazing one ✅🚩

  • @MohamadMirSajadi
    @MohamadMirSajadi 10 месяцев назад +1

    it was ,nice , clear and what i was looking for . Thank you

    • @be-devops
      @be-devops  10 месяцев назад

      Thanks for the nice comment. لطف دارید

  • @LucasAragãoA.daCosta
    @LucasAragãoA.daCosta 2 месяца назад +1

    amazing tutorial, ty

  • @user-mp6pq3pd9w
    @user-mp6pq3pd9w 4 месяца назад +1

    Thank you, very helpful.

    • @be-devops
      @be-devops  3 месяца назад

      Glad to hear it!

  • @sergekomi6039
    @sergekomi6039 6 месяцев назад +1

    great explanation very helpful thank you !!!

  • @ahosanhabib9399
    @ahosanhabib9399 5 месяцев назад +1

    Great teaching

  • @timpomaville3080
    @timpomaville3080 6 месяцев назад

    These videos are wonderful!

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Development of skills and Wisdom and experience and learning education po

  • @lenoah8692
    @lenoah8692 8 месяцев назад

    best teacher thanks

  • @mostafabanaei2832
    @mostafabanaei2832 8 месяцев назад +1

    thank you for great video

    • @be-devops
      @be-devops  8 месяцев назад

      It is my pleasure

  • @somber2075
    @somber2075 6 месяцев назад

    Great video. It has helped me a lot

  • @AI-4-U
    @AI-4-U 11 месяцев назад +3

    Can you please do a video on these topics.
    1. Helm charts
    2. Istio service mesh
    3. Observability with OpenTelemetry
    4. GitOps, ArgoCD

    • @be-devops
      @be-devops  11 месяцев назад +1

      Good Ideas, sure will do

    • @neelojp8460
      @neelojp8460 11 месяцев назад +1

      @@be-devops yes please about Helm :-)

    • @be-devops
      @be-devops  11 месяцев назад +1

      @@neelojp8460 I am preparing it

  • @rikitikitaki5919
    @rikitikitaki5919 4 месяца назад +1

    Good video, but you didnt mention about runner. I think it was full cicd process if you showed installing runner

    • @be-devops
      @be-devops  4 месяца назад

      Thank you for your comment
      Here we more focus on CICD. But i had another video about using gitlab runner:
      ruclips.net/video/6BlsKlhOhDE/видео.html

    • @rikitikitaki5919
      @rikitikitaki5919 4 месяца назад +1

      ​@be-devops Could you explain me, please. In stage deploy, do we need to use kubernetes runner? Or it is enought that we have agent. Because when i am starting my pipeline it gives me error, that here we dont have runner to deploy. Maybe i have a mistake.

    • @be-devops
      @be-devops  4 месяца назад

      @@rikitikitaki5919 no need something like you say kubernetes runner. we do not have such thing.
      Only agent is ok
      you can contact me by email and send me the issue logs and we can solve it quickly

    • @be-devops
      @be-devops  4 месяца назад

      @@rikitikitaki5919 howtoskillsvid@gmail.com

  • @sfarpaktech
    @sfarpaktech 9 месяцев назад

    Really helpful thanks for sharing

  • @ceasarpalache1045
    @ceasarpalache1045 4 месяца назад +1

    Make sure your k8s-connection is in the same group as the project you're trying to deploy. If it's not, the deployment step will fail trying to set kubectl contexts.

  • @sharukhannadagoud
    @sharukhannadagoud 5 месяцев назад

    awesome video

  • @eliaspereira777
    @eliaspereira777 7 месяцев назад +1

    Hello, great explanation!!!
    I have a gitlab-ci.yml identical to yours, but in the build stage, I set the tags: build, only.
    The deploy is identical. When I push, the stage build completes successfully, but the stage deploy
    is waiting for a runner. I believe that with the gitlab agent, there is no need for a runner, correct?

    • @be-devops
      @be-devops  7 месяцев назад

      yes deploy also need gitlab runner, because you are using an image to run kubectl command
      check yr deploy config. or send me by email to check it for you
      howtoskillsvid@gmail.com

  • @danishkhalid9193
    @danishkhalid9193 10 дней назад +1

    I followed your step when deploying application manually in k8s cluster , i did the same thing but i am unable to access the application using internal IP of the cluster but i am able to access it through localhost:nodeport . What might haves caused this problem or is it not a problem at all ? Thanks

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Superior of all physicians group multidisciplinary plan and professionalism for all the healthcare workers po

  • @elchinefa9524
    @elchinefa9524 4 месяца назад +1

    First of all thnaks a lot for this video. I am fasinf agent connection issue. I'm using our company gitlab server and Connect a Kubernetes cluster return an error: Gitlab Failed to register an agent GRPC::Unimplemented . By the way my kubernetes running in Proxmox and it is kubeadm cluster.

    • @be-devops
      @be-devops  4 месяца назад

      Please check in Kubernetes Cluster that Helm chart installed successfully and agent is running.
      you can reach me by email and we can discuses on it

    • @elchinefa9524
      @elchinefa9524 3 месяца назад

      @@be-devops Where can i find your email.

    • @be-devops
      @be-devops  3 месяца назад

      @@elchinefa9524 howtoskillsvid@gmail.com

  • @nikitamathur6720
    @nikitamathur6720 5 месяцев назад +1

    Thanks for the detailed Video. Help me alot !!!
    Want to ask you that when i run 'kubectl get node -o wide' and take the internal ip of the node-cluster, i am not able to connect to my app on browser.
    I have installed docker for windows on my windows machine. Then minicube for Kubernetes. Should i install anything else.

    • @be-devops
      @be-devops  5 месяцев назад

      Please check your firewall on windows and maybe blocked it
      but as i described I am using Rancher Desktop and really is amazing
      for its installation you can check my other video:
      ruclips.net/video/I9YtRhPRMqc/видео.html

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    New development for skills Experience wisdom creativity and all my talents and wisdoms righteousness obedience training equipment po

  • @happyshoppi1036
    @happyshoppi1036 6 месяцев назад +1

    Hi Thankyou so much for your video I have made a similar lab for testing CICD Gitlab I am facing issues whule pusing the code in gitlab container I would appreciate your help

  • @serokanikani
    @serokanikani 5 месяцев назад

    thanks for the tutorial, I have a problem if I update coding and push to gitlab, build image and deploy successfully.
    but it seems like the pod or service or image in microk8s is not updated
    and if I delete the service and pod first then push to gitlab, its work. my gitlab ci yaml is same with tutorial

  • @JavierParadaHD1
    @JavierParadaHD1 4 месяца назад

    Teacher i have a problem, in the same group i have acces to the k8s aggent with every project without any problem, but when i need the k8s agent in another group i have'nt access, and i've already added the ci_access project and group to access it, but it doesn't work :((. I've my own self hosted gitlab and i've put as true the gitlab_kas['enable']. Help pls

  • @Freeline95
    @Freeline95 7 месяцев назад

    Nice video!
    Could you give me advice by best practices.
    In your case you store k8s yaml files in your project repo. But i am developing microservices architecture and my files are storing in separated repo "infrastructure".
    How to get files from there? Git clone my private repo during the build?

    • @be-devops
      @be-devops  7 месяцев назад

      Hi Friend,
      You can find your answer here in this video:
      ruclips.net/video/OvgXuGskdCM/видео.html
      I described there how to clone other repo in CICD

  • @shashankmr2482
    @shashankmr2482 5 месяцев назад

    You didn't mention runners there

  • @Rajasubbiah-x1k
    @Rajasubbiah-x1k 9 месяцев назад +1

    Hi bro, thanks for the video. May I know how to access the source code

    • @be-devops
      @be-devops  9 месяцев назад

      In description there is Github repo address.
      but here you are:
      All Files related to this Project: (1-K8S-CICD folder)
      github.com/mkaraminejad/cicd_pipeline

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    And god po

  • @dattran3130
    @dattran3130 10 месяцев назад +1

    Hello ad, can you share me the repo of web in k8s-data. Very thanks you

    • @be-devops
      @be-devops  10 месяцев назад

      I added this repo in description
      github.com/mkaraminejad/cicd_pipeline.git
      folder 1-K8S-CICD

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Sir/Dr. mark Anthony familaran po and mommy/dr.Carmela domocmat po

  • @user-wj8qz8me2l
    @user-wj8qz8me2l 3 месяца назад

    Thank you ! But i have never connected status !! and i have a "Failed to register agent pod. " problem ! Can you help please !?

    • @be-devops
      @be-devops  3 месяца назад +2

      Thank you for your comment.
      To make connection I would check cluster side. I suggest you when in gitlab side you create a connection, copy helm codes and past them in Cluster side.
      After please check if everything in cluster side working well:
      1) kubectl get ns
      you will see the name spaces and also the one for gitlab
      2) kubectl -n get pods
      ex:
      kubectl -n gitlab-agent-k8s-connection get pods
      the result will show you the pods should be in running status.
      If pods be in Running status but still you have no connection in gitlab, check your firewall
      You can reach me by Email.

    • @user-wj8qz8me2l
      @user-wj8qz8me2l 3 месяца назад

      @@be-devops Can you give me your email please ?

  • @hwy9nightkid
    @hwy9nightkid 8 месяцев назад

    at about 29:26 you're showing the building of the image with a public gitlab provided runner.. is the agent also capabale of building or how should one go about supporting not just operations but build steps in our private k8s? seems I need more runner types installed?

    • @be-devops
      @be-devops  8 месяцев назад

      Hello, I did not get your question
      would you please send me more details in my email
      howtoskillsvid@gmail.com

    • @hwy9nightkid
      @hwy9nightkid 8 месяцев назад

      I'd rather not reveal my email.. but I think I understand.. you built the docker image using gitlabs free runners... I wanted to see if you could build docker images within the k3s cluster.. but very good video thanks ! @@be-devops

    • @be-devops
      @be-devops  8 месяцев назад

      @@hwy9nightkid Good Hint. I will check K3S and will try to do. Thanks

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    🙏😇

  • @shivendrasingh5550
    @shivendrasingh5550 8 месяцев назад

    When the Docker image has already been built in the gitlab registry. Why do we need to push it again? Won't the image be there already?

    • @be-devops
      @be-devops  8 месяцев назад

      When it had been built by CICD , it is located on gitlab runner and when the job done by gitlab runner it will gone because it is a container so we need to push it on gitlab repository that be useable

    • @shivendrasingh5550
      @shivendrasingh5550 8 месяцев назад +1

      @@be-devops Thankyou for the prompt response. Please also make a video on how helm charts, gitlab-ci.yaml, Dockerfile and Docker-compose.yaml are related?
      I have seen all of them in a single project and could not understand the use of all of them.

    • @be-devops
      @be-devops  8 месяцев назад

      @@shivendrasingh5550 check my latest video in my channel using helm chart with CICD to deploy on K8S

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Physicians group multidisciplinary plan

  • @user-ow5vr5nz4r
    @user-ow5vr5nz4r 10 месяцев назад

    inmy case i have installed kubecluster in my local environment when i did the same as you presented my agent is not connecting.
    can you provide any solution for that.

    • @be-devops
      @be-devops  10 месяцев назад

      do you have access to your kube cluster from your local machine terminal? for example if you open yr terminal and type "kubectl get node -o wide" works?
      because at first you have to be sure you cluster works well. contact me by "howtoskillsvid@gmail.com" and we can solve the issue

    • @nikhiltaneja9825
      @nikhiltaneja9825 Месяц назад

      Same with me. Any idea why its happening?

    • @user-ow5vr5nz4r
      @user-ow5vr5nz4r Месяц назад

      @@nikhiltaneja9825 i have solved my issue what exactly the problem u r facing?

    • @user-ow5vr5nz4r
      @user-ow5vr5nz4r Месяц назад

      @@nikhiltaneja9825 my issue was resolved can u b more specific of the issue?

  • @praveenchaudhary288
    @praveenchaudhary288 9 месяцев назад

    getting an error occurred while loading your agents

    • @be-devops
      @be-devops  9 месяцев назад

      your k8s cluster is in remote or local?

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    New cluster and projects po

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Sir Henry and sir Aiken and sir danni Po and madam butterfly and madam/Dr. Carolyn and madam divine and madam mercy and madam Kris amoyo po and madam grace po

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    God and whole dragons teams po Kuya Bobby and ate Anna Po and bata Po kami ni thel Po mommy Carmela Po

  • @user-ij4hg8pi1f
    @user-ij4hg8pi1f 9 месяцев назад

    Thank you god and sir mark Anthony familaran po and mommy Carmela Po box online and meetings Po 🤝🐉 Kuya Bobby and ate Anna Po nakakainis maraming thesis papers natin Po

  • @stream4885
    @stream4885 8 месяцев назад +1

    Thank you for your video and presentation. after following deployment is ok and manual deployment also work, but i have this message at the end of cd/cd process. any clue why? thank you @be_devops
    .gitlab-ci.yml": error validating data: [apiVersion not set, kind not set]; if you choose to ignore these errors, turn validation off with --validate=false

    • @be-devops
      @be-devops  7 месяцев назад

      Please share me the content of .gitlab-ci.yml by my email: howtoskillsvid@gmail.com