Day 11/40 - Multi Container Pod Kubernetes - Sidecar vs Init Container

Sdรญlet
Vloลพit
  • ฤas pล™idรกn 2. 07. 2024
  • Welcome to day 11/40 of the Certified Kubernetes Administrator (CKA) Full Course. In this video, we will explore multi-container pods in Kubernetes with a detailed conceptual explanation, a live demo, and an engaging hands-on assignment.
    In this video, you'll learn:
    - What are environment variables in Kubernetes, and how do we use that
    - Introduction to multi container pod in kubernetes
    - How to create an init container inside a pod
    - Commands and arguments in Kubernetes pod yaml
    - Demo and troubleshooting
    ๐Ÿš€ Reinforce your knowledge with practical tasks in the Day 11 folder of our GitHub repository: github.com/piyushsachdeva/CKA...
    ๐Ÿ‘จ๐Ÿผโ€๐Ÿ’ป #40daysofKubernetes Challenge:
    Join our 40-day challenge and solidify your Kubernetes skills. Details can be found in the "#40daysofkubernetes.md" file on GitHub or by watching our Day 0 video.
    ๐Ÿ“– Course Schedule:
    I'll release 3-4 videos per week and host live Q&A sessions on weekends to answer your questions and guide you through the CKA certification process.
    ๐Ÿ•ต๐Ÿปโ€โ™‚๏ธ Who Should Watch:
    This CKA course is designed for beginners, college students, and working professionals who want to learn Kubernetes from scratch, prepare for the CKA certification exam, or enhance their knowledge. It was designed based on the latest curriculum for the CKA exam in May 2024 and uses 1.30.2 as the Kubernetes version.
    Let's start your Kubernetes journey together!
    ๐—–๐—ข๐— ๐—ฃ๐—Ÿ๐—˜๐—ง๐—˜ ๐—ง๐—จ๐—ง๐—ข๐—ฅ๐—œ๐—”๐—Ÿ ๐—ฆ๐—˜๐—ฅ๐—œ๐—˜๐—ฆ ๐Ÿ‘Œ Itโ€™s ๐Ÿ…ต๐Ÿ†๐Ÿ…ด๐Ÿ…ด โ›ณ
    โœ… ๐—”๐˜‡๐˜‚๐—ฟ๐—ฒ ๐——๐—ฒ๐˜ƒ๐—ข๐—ฝ๐˜€ ๐—ญ๐—ฒ๐—ฟ๐—ผ ๐˜๐—ผ ๐—›๐—ฒ๐—ฟ๐—ผ:
    โ€ข Azure DevOps Zero to H...
    โœ… ๐—”๐—ญ๐Ÿต๐Ÿฌ๐Ÿฌ ๐—”๐˜‡๐˜‚๐—ฟ๐—ฒ ๐—™๐˜‚๐—ป๐—ฑ๐—ฎ๐—บ๐—ฒ๐—ป๐˜๐—ฎ๐—น๐˜€ ๐—™๐˜‚๐—น๐—น ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ
    โ€ข AZ900WithPiyush - Azur...
    โœ… ๐—ก๐—ฎ๐—บ๐—ฎ๐˜€๐˜๐—ฒ ๐—š๐—ผ๐—ผ๐—ด๐—น๐—ฒ ๐—–๐—น๐—ผ๐˜‚๐—ฑ | ๐—š๐—–๐—ฃ ๐—ง๐˜‚๐˜๐—ผ๐—ฟ๐—ถ๐—ฎ๐—น ๐—ณ๐—ผ๐—ฟ ๐—ฏ๐—ฒ๐—ด๐—ถ๐—ป๐—ป๐—ฒ๐—ฟ๐˜€, ๐—ฎ ๐—ฐ๐—ผ๐—บ๐—ฝ๐—น๐—ฒ๐˜๐—ฒ ๐—ฝ๐—น๐—ฎ๐˜†๐—น๐—ถ๐˜€๐˜ ๐—ณ๐—ผ๐—ฟ ๐˜๐—ต๐—ฒ ๐—”๐˜€๐˜€๐—ผ๐—ฐ๐—ถ๐—ฎ๐˜๐—ฒ ๐—–๐—น๐—ผ๐˜‚๐—ฑ ๐—˜๐—ป๐—ด๐—ถ๐—ป๐—ฒ๐—ฒ๐—ฟ (๐—”๐—–๐—˜) ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—˜๐˜…๐—ฎ๐—บ:
    โ€ข Namaste Google Cloud, ...
    โœ… ๐—”๐˜‡๐˜‚๐—ฟ๐—ฒ ๐——๐—ฎ๐˜๐—ฎ ๐—ณ๐˜‚๐—ป๐—ฑ๐—ฎ๐—บ๐—ฒ๐—ป๐˜๐—ฎ๐—น๐˜€ ๐——๐—ฃ ๐Ÿต๐Ÿฌ๐Ÿฌ ๐—ณ๐˜‚๐—น๐—น ๐—ฐ๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ
    โ€ข Microsoft Azure Data F...
    โœ… ๐—๐—ฒ๐—ป๐—ธ๐—ถ๐—ป๐˜€ ๐—ง๐˜‚๐˜๐—ผ๐—ฟ๐—ถ๐—ฎ๐—น ๐—ณ๐—ผ๐—ฟ ๐—•๐—ฒ๐—ด๐—ถ๐—ป๐—ป๐—ฒ๐—ฟ๐˜€
    โ€ข Jenkins Tutorial For B...
    โœ… #๐Ÿญ๐Ÿฌ๐˜„๐—ฒ๐—ฒ๐—ธ๐˜€๐—ผ๐—ณ๐—ฐ๐—น๐—ผ๐˜‚๐—ฑ๐—ผ๐—ฝ๐˜€ - ๐—ฅ๐—ฒ๐—ฎ๐—น-๐˜๐—ถ๐—บ๐—ฒ ๐—ฐ๐—ผ๐—บ๐—ฝ๐—น๐—ฒ๐˜… ๐—ต๐—ฎ๐—ป๐—ฑ๐˜€-๐—ผ๐—ป ๐—ฝ๐—ฟ๐—ผ๐—ท๐—ฒ๐—ฐ๐˜๐˜€ ๐—ผ๐—ป ๐—–๐—น๐—ผ๐˜‚๐—ฑ ๐—ฎ๐—ป๐—ฑ ๐——๐—ฒ๐˜ƒ๐—ข๐—ฝ๐˜€
    โ€ข 10WeeksOfCloudOps Chal...
    โœ… ๐——๐—ฒ๐˜ƒ๐—ข๐—ฝ๐˜€ ๐—ฎ๐—ป๐—ฑ ๐—–๐—น๐—ผ๐˜‚๐—ฑ ๐—ฃ๐—ผ๐—ฑ๐—ฐ๐—ฎ๐˜€๐˜๐˜€:
    โ€ข DevOps and Cloud Podcasts
    โœ… ๐—š๐—ถ๐˜๐—น๐—ฎ๐—ฏ ๐—–๐—œ ๐—–๐—— ๐—ง๐˜‚๐˜๐—ผ๐—ฟ๐—ถ๐—ฎ๐—น | ๐—˜๐—ป๐—ฑ ๐—ง๐—ผ ๐—˜๐—ป๐—ฑ ๐—ฅ๐—ฒ๐—ฎ๐—น-๐˜๐—ถ๐—บ๐—ฒ ๐—ฃ๐—ฟ๐—ผ๐—ท๐—ฒ๐—ฐ๐˜ [๐—™๐˜‚๐—น๐—น ๐—–๐—ผ๐˜‚๐—ฟ๐˜€๐—ฒ]
    โ€ข Gitlab CI CD Tutorial ...
    Subscribe to our channel to get notified about the latest videos.
    ๐Ÿ”ฅ / techtutorialswithpiyush
    -----------------------------------------------------------------------------------------------------------------------
    ๐—–๐—ผ๐—ป๐—ป๐—ฒ๐—ฐ๐˜ ๐—บ๐—ฒ ๐—›๐—ฒ๐—ฟ๐—ฒ:๐Ÿ‘‡๐Ÿ‘‡
    ๐Ÿ”ฅ๐—ฌ๐—ผ๐˜‚๐—ง๐˜‚๐—ฏ๐—ฒ โ–ถ / techtutorialswithpiyush
    โ›ณ๐—Ÿ๐—ถ๐—ป๐—ธ๐—ฒ๐—ฑ๐—œ๐—ป โ–ถ / piyush-sachdeva
    ๐Ÿš€๐—œ๐—ป๐˜€๐˜๐—ฎ๐—ด๐—ฟ๐—ฎ๐—บ โ–ถ / techtutorialswithpiyush
    ๐ŸŒ๐—ง๐˜„๐—ถ๐˜๐˜๐—ฒ๐—ฟ โ–ถ / techie_piyush
    ๐Ÿ‘จโ€๐Ÿ’ป ๐—š๐—ถ๐˜๐—ต๐˜‚๐—ฏ โ–ถ github.com/piyushsachdeva
    โœ ๐— ๐—ฒ๐—ฑ๐—ถ๐˜‚๐—บ.๐—ฐ๐—ผ๐—บ โ–ถ / piyush.sachdeva055
    ๐Ÿ“š ๐—ฑ๐—ฒ๐˜ƒ.๐˜๐—ผ โ–ถ dev.to/piyushsachdeva
    โœจ๐——๐—ถ๐˜€๐—ฐ๐—ผ๐—ฟ๐—ฑ โ–ถ / discord
    -----------------------------------------------------------------------------------------------------------------------
    References ๐Ÿ“š:
    #devops #techtutorialswithpiyush
  • Vฤ›da a technologie

Komentรกล™e • 34

  • @kirangundamala8434
    @kirangundamala8434 Pล™ed 20 dny +2

    Nice Explanation

  • @password301992
    @password301992 Pล™ed 16 dny +2

    Simplified eplanation ! Loved it

  • @narasimhasaladi7
    @narasimhasaladi7 Pล™ed 21 dnem +3

    dont worry bro ur hadwork pays off u soon ,
    when every one get into the world of kubernetes u will boom like anything ,best of luck
    ๐Ÿงฟ

  • @sagarbirla2879
    @sagarbirla2879 Pล™ed 20 dny +2

    amazing explaination

  • @satishalla
    @satishalla Pล™ed 24 dny +2

    Nice explanation

  • @kunalbagwe6091
    @kunalbagwe6091 Pล™ed 8 dny

    Bro you are a TECH GURU for us. Thanks Piyush bhai.

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 7 dny

      Just someone who's trying to help โค๏ธ not a guru , but thank you for the kind words

  • @kundankumar5395
    @kundankumar5395 Pล™ed 9 dny +1

    It was a great session....

  • @dheerajkasaudhan1244
    @dheerajkasaudhan1244 Pล™ed 22 dny +1

    Nice detailed explanation >>

  • @artbart9080
    @artbart9080 Pล™ed 27 dny

    Nice video.Waiting for others...

  • @floehden
    @floehden Pล™ed 28 dny

    Thank you for this! It's mostly better, to see the database up, before the webservice can access it. thank you for showing how to do this

  • @ebenezerbarning5093
    @ebenezerbarning5093 Pล™ed 28 dny

    great job Piyush sir. u always make complex concept look easy. u are the best. thanks again

  • @NithishkumarP-ug2em
    @NithishkumarP-ug2em Pล™ed 27 dny +1

    Nice explanation....

  • @brahmaiahboddu5762
    @brahmaiahboddu5762 Pล™ed 28 dny

    Hi Piyush,
    Thanks for the detailed explanation of the init container
    What about a sidecar container.

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 27 dny

      sidecar containers are being created when you use an application that needs to gather some metrics/data from your pod itself. Monitoring application such as datadog is one of the usecase. We will cover that in a seperate video.

    • @brahmaiahboddu5762
      @brahmaiahboddu5762 Pล™ed 27 dny

      @@TechTutorialswithPiyush Thanks for the explanation Piyush

  • @nope-ms4rx
    @nope-ms4rx Pล™ed 17 dny +2

    like @narasimhasaladi7 said. Very soon! Your tutorials will be integral for less technical folks learning K8s! Only way is up! Keep going strong.

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 16 dny +1

      My goal is to simplify the learning of advance topics so that anyone can learn and take advantage of it. thank you for the support.

  • @karnajeetsawant5635
    @karnajeetsawant5635 Pล™ed 28 dny

    Hi Piyush. Thanks for making the concept easier. I have a question though. Can there be a situation where a deadlock occurs between the init container and the pod. If such a situation arises then how would one solve it?

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 27 dny

      Thank you for the feedback. There wouldnt be a deadlock situation as init containers are always executed first and only after the successfull completion of init container, your main container will be executed.

  • @debillion
    @debillion Pล™ed 24 dny +1

    Instead of each pod having its own sidecar container, is it possible for mutiple pods to use one shared pod container located somewhere? if yes, how can it be done?

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 23 dny

      Replied this over the livestream but let me add the answer here as well. It is not possible for multiple pods to use one shared pod/container. It involves a lot of dependency on that shared container and other pods will be impacted if something happens to the shared container, it make the application tightly couple which is an anti-pattern of microservices.

    • @debillion
      @debillion Pล™ed 15 dny +1

      @@TechTutorialswithPiyush Thanks for your reply. However, I am still not very clear.
      Once again, I have a bitbucket Pipelines. I want to use one shared Docker pod instead of the same sidecar in every pod.
      I have both the runner container and Docker container in a manifest but I wanted to know how to seperate the runner container from the docker container (sidecar container) so that I can run one Docker instance and multiple runner instances on one Kubernetes node.

    • @TechTutorialswithPiyush
      @TechTutorialswithPiyush  Pล™ed 15 dny

      @@debillion can you join our discord community and share the issue in help-general channel?
      thecloudopscommunity.org