How to Build and Deploy an app Helm Chart on Kubernetes Cluster with GitLab CI/CD

แชร์
ฝัง
  • เผยแพร่เมื่อ 4 ก.ค. 2024
  • In this comprehensive tutorial, dive into the intricacies of deploying Helm Charts on a Kubernetes cluster using the power of GitLab CI/CD pipelines. Learn step-by-step how to automate and streamline your application deployment process, leveraging the seamless integration between Helm and GitLab. From setting up your CI/CD pipeline to understanding Helm Charts and their deployment nuances, this video will equip you with the knowledge and skills to efficiently manage and scale your applications in a Kubernetes environment. Join us on this journey to mastering Helm and GitLab CI/CD for a more efficient and robust deployment workflow. Elevate your DevOps game and ensure smoother releases with this in-depth guide.
    www.buymeacoffee.com/karaminejad
    Resource files for this project on my github:
    github.com/mkaraminejad/cicd_...
    00:00:00 Pre-Introduction
    00:00:56 Introduction
    00:02:55 Scenario description
    00:04:25 Lab Requirements
    00:06:00 Install Gitlab agent on K8S
    00:13:05 Test Agent connection to K8S
    00:18:18 Prepare App Image
    00:27:00 Push App Image to Gitlab Image Registry by CICD
    00:34:20 Create Helm chart
    00:38:06 Install Helm Chart on K8S Manually
    00:40:11 Publish Helm chart to helm Repo Manually
    00:45:15 Create, Publish and deploy Helm Chart to K8S by CICD
    01:00:22 Uninstall Helm Chart by CICD

ความคิดเห็น • 29

  • @cleitonpena4578
    @cleitonpena4578 3 หลายเดือนก่อน +3

    Hi Malek, thank you for your lessons. You have a super didactic, and you don't edit the video in the errors, you face all the steps.
    You deserve much more than 5 coffees.

    • @be-devops
      @be-devops  3 หลายเดือนก่อน +1

      Thank you so much

  • @Mandarnold
    @Mandarnold 21 วันที่ผ่านมา +1

    Great Tutorial - with some hints from the comments and some research its now working and should be a good base for bigger projects... 👍👊🙂

    • @be-devops
      @be-devops  21 วันที่ผ่านมา

      Thanks

  • @lenint3341
    @lenint3341 3 หลายเดือนก่อน +1

    excellent! thank you

  • @wpuncensored
    @wpuncensored 4 หลายเดือนก่อน +1

    Great video, THANK YOU!

    • @be-devops
      @be-devops  4 หลายเดือนก่อน

      Thank you

  • @KariemSoudy
    @KariemSoudy 25 วันที่ผ่านมา +1

    you could use helm show chart to extract the chart data :)

  • @manoharkodurivlogs4460
    @manoharkodurivlogs4460 12 วันที่ผ่านมา

    I did same setup I have created seperate repo for the girlab-agent to k8s cluster and when I try to run the pipeline agent will connect to the cluster and I'm getting kubect pods details
    But when I created pipeline and in another repo I'm not able to connect cluster?

  • @kamilorowski8052
    @kamilorowski8052 3 หลายเดือนก่อน +1

    What when I have more repositories(each for one microservice)? Do I have to configure gitlab agent on k8s for each of them? I created 2 repositories, first one k8s-gitlab-connection where Kubernetes cluster is configured in Gitlab and agent was installed on k8s cluster. There is connection, it works. But I have an another repository microservice-1-repository, when I configured the pipeline I'm getting "error: no context exists with the name: xxx" for this command "kubectl config use-context: xxx". I guess this happeing because I don't have Kubernetes cluster integration for this specific project. But I don't want to do it for each repository...

    • @kamilorowski8052
      @kamilorowski8052 3 หลายเดือนก่อน

      I found an answer, I changed config.yaml by adding
      ci_access:
      # This agent is accessible from CI jobs in projects in these groups
      groups:
      - id: gitlab/repository/group
      then all my miscroservices can see k8s connections!
      great content! thx!!!!

  • @shreedevatha4205
    @shreedevatha4205 3 หลายเดือนก่อน

    Great Video. Looking to see if an application like JIRA has a license key when launching it. How can the license key be added into the values.yaml file?

  • @neelojp8460
    @neelojp8460 6 หลายเดือนก่อน +1

    Thank you so much, this was the answer on my last question 🙂your explanations are consistently excellent, always making complex topics easy to understand...So if I make any changes to the deployments.yaml I have to push that again to the registry or not? if i want to update the YAML files inside the template folder... that would be also helpful if we know that... thanks again

    • @be-devops
      @be-devops  6 หลายเดือนก่อน +1

      Thank you

  • @RohanPatil-nq7ey
    @RohanPatil-nq7ey 4 หลายเดือนก่อน +1

    Great Video Sir! Can you please share how to install the runner as well! As it is not included in the video! Thank You! :)

    • @be-devops
      @be-devops  4 หลายเดือนก่อน

      Hello Rohan
      I have a Video about it: th-cam.com/video/6BlsKlhOhDE/w-d-xo.html

  • @thewarrior9827
    @thewarrior9827 6 หลายเดือนก่อน +1

    Really nice presentation.
    Do you mind sharing your git? It would be so useful.

    • @be-devops
      @be-devops  6 หลายเดือนก่อน

      Thank you

  • @kylejones4040
    @kylejones4040 4 หลายเดือนก่อน +1

    Great video! I am stuck at one part. It's probably obvious, but the secret file is a dockerconfigjson type. The .dockerconfigjson base64 string returns an illage base64 data input. Do we need to create our own json file for gitlab or docker here? @38:45

    • @be-devops
      @be-devops  4 หลายเดือนก่อน

      For secret that uses dockerconfigjson, you can just once type in your terminal:
      docker login registry.gitlab.com
      then ask you username and password and will show you login success.
      so now if you check :
      ls ".docker/config.json " it will show you the config.json file is there with the following content:
      {
      "auths": {
      "registry.gitlab.com": {}
      },
      "credsStore": "wincred.exe"
      }
      so for create secret you can use this config.json file like below:
      kubectl create secret docker-registry my-secret --from-file=.dockerconfigjson=config.json --dry-run=client -o yaml > secret.yaml
      also you can reach me by email to discuss about it: howtoskillsvid@gmail.com

  • @arjipurnavenkatesh7163
    @arjipurnavenkatesh7163 5 หลายเดือนก่อน

    Thank you so much. I tried to implement the same usecase. However, it is only working when configuring my container registry, helm chart registry, kubernetes connection operator in one Gitlab project. If I split, I am getting "error: no context exists with the name:". Not sure how you managed to make it work in three different project. Appreciate your help in this case.

    • @be-devops
      @be-devops  5 หลายเดือนก่อน

      Thank you so much for your consideration:
      1- create 1st repo for connection between your gitlab and K8s and also test it via CI/CD
      2- Create 2ed repo for your Data/Helm chart, etc. Then allow it access to Tunnel between 1st repo and k8s by allowing it in config.yaml
      EX:
      ci_access:
      projects:
      - id: d6245/helm_project
      You can reach me out by email:
      howtoskillsvid@gmail.com

  • @ratomarsupial1
    @ratomarsupial1 3 หลายเดือนก่อน

    Thank you for the the video and for the great content. I am getting an error when deploying the app manually on my k8s cluster. my pod status is "ErrImagePull". Do I need to use another image besides the one I deployed in the gitlab container registry?

    • @be-devops
      @be-devops  3 หลายเดือนก่อน

      When you get "ErrImagePull", you have to check the logs ok K8s. please type:
      #kubectl describe pod
      and see why you get this error.
      if it is related to authentication do:
      #docker login registry.gitlab.com
      Then ask enter username and token. if login successful try to manually create your pod and in this time should be OK

  • @sylvain351
    @sylvain351 6 หลายเดือนก่อน

    hi, have you a repo for this demo ? regards

    • @be-devops
      @be-devops  6 หลายเดือนก่อน

      github.com/mkaraminejad/cicd_pipeline