MetalLB and NGINX Ingress // Setup External Access for Kubernetes Applications

Sdílet
Vložit
  • čas přidán 22. 05. 2023
  • Learn how to install MetalLB Load Balancer and NGINX Ingress controller in Kubernetes.
    GitHub Project: github.com/morrismusumi/kuber...

Komentáře • 134

  • @EngineeringWithMorris
    @EngineeringWithMorris  Před 11 měsíci +14

    GitHub project with all the manifests and setup instructions is linked in the description.

  • @rukzmrlonely
    @rukzmrlonely Před 4 měsíci +13

    Nice and crisp.
    I usually see training videos at 1.25 to 1.5 x speed. But this is the first time I slowed the video to .75 x😂

    • @raghavendarsridhar4403
      @raghavendarsridhar4403 Před 3 měsíci +1

      Its the only video I got on youtube explaining this, Thank you But I had to play it in 0.5x

  • @archiet7t705
    @archiet7t705 Před měsícem +3

    This is the best kubernetes Load balancer and Ingress controllers explainer video I have seen

    • @IceMan7812
      @IceMan7812 Před 6 dny

      agree, simple and to the point

  • @VijetCP
    @VijetCP Před 6 měsíci +3

    Thank you for making a clear and crisp video explaining a hard topic along with neat demos in 10 minutes

  • @girthquake8523
    @girthquake8523 Před 10 měsíci +6

    Just started learning Kubernetes and this is the most clear/concise explanation on services I've seen. Thanks for helping me get MetalLB running in my local test cluster. Great content Morris!

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 10 měsíci +2

      Thanks a lot for watching, and for the positive feedback, I am glad it was helpful.

  • @hitmanLis
    @hitmanLis Před měsícem +2

    dude you are really the first person to explain exactly what we need. Layed it all out perfectly, in nice detail and flow! Great job. First time see your vid. already subscribed and liked the video!

  • @JonathanSomersIsAwesome
    @JonathanSomersIsAwesome Před 4 měsíci

    I've been struggling with these concepts for a bit, this really helped make it click. Thanks!

  • @user-bc3fs7et5j
    @user-bc3fs7et5j Před 8 měsíci

    Great video, helped when configuring Metallb & Ingress Nginx Controller. I wish there were more such detailed video tutorials

  • @Hayzin
    @Hayzin Před 11 měsíci +1

    Excelent explanation about loadbalancer and metallb!

  • @eduardpanov1921
    @eduardpanov1921 Před 3 měsíci

    Nice, calm and concise explanation. I've been searching this for a whole day. Thank you.

  • @jonbrule2897
    @jonbrule2897 Před 2 měsíci

    An outstanding video. Your overview and detailed step thru is clear and thorough! Keep up the great work!

  • @yunielalvarez5158
    @yunielalvarez5158 Před 8 měsíci

    Thank you for this video, it has been very useful for me. I have been trying to configure Metallb in my Kubernetes cluster for more than 15 days and I needed to create the L2Advertisement. Without this video it would never have worked for me. Thank you very much for the help.

  • @rixonmathew
    @rixonmathew Před 4 měsíci

    Nice job in explaining concept and getting started in a very clear and crisp manner.👍

  • @victornoagbodji
    @victornoagbodji Před 10 měsíci +5

    Outstanding overview that not only covers service types but load balancers and how to set up MetalLB. Thanks for making the video! 😊🙏

  • @vladimirkulyashov1417
    @vladimirkulyashov1417 Před 7 měsíci

    Thank you! I've been stuck with the problem for a couple of days. Came out that I had no L2 Advertisement applied to my MetalLB. Worked like a charm! :)

  • @oleksandrshalbanov2685
    @oleksandrshalbanov2685 Před 2 měsíci

    Thx man, this is the first video I found, that explained all the process from metallb setup to ingress configuration

  • @cigarettesafter9435
    @cigarettesafter9435 Před 2 měsíci

    Super simple and straight to the point. Incredibly clear. Well done!

  • @oddmen
    @oddmen Před 3 měsíci

    You explain the contents so simply and understandably that it is impossible not to learn.
    Thanks bro.

  • @jpbarcelos
    @jpbarcelos Před 7 měsíci +2

    Dude, this video is a work of art. Seriously. Thank you. It really nails the explanation.

  • @Tendeza_
    @Tendeza_ Před 22 dny

    Clear explanation and good tutorial, actually works!

  • @sunosound
    @sunosound Před 3 měsíci

    Thanks Morris, super simple and complete explanation! Now I have a MetalLB installed on my bare-metal. Awesome 👏👏👏

  • @wecharg
    @wecharg Před 6 měsíci

    I skipped over this the first time, when I came back and stayed with it I learned a bit, thanks!

  • @leonardolimaribeiro8282
    @leonardolimaribeiro8282 Před 8 měsíci

    This video was SUPER helpful for me. Thanks, man!

  • @Akimbo711
    @Akimbo711 Před měsícem

    I was having a nightmare trying to find a video that explained what I was trying to do - this nailed it
    Thank you

  • @ammekilde1
    @ammekilde1 Před 10 měsíci

    Best video on metallb and ingress i have seen. Thanks for the work

  • @olegfranko8675
    @olegfranko8675 Před rokem +3

    Thanks for the great content and explanation.
    I would have expected a lot more views and likes on your videos.
    Hopefully your channel will grow with time;))

  • @IamKanuKingsley
    @IamKanuKingsley Před 6 měsíci

    I have been blessed with this video. Wow! Thanks a lot.

  • @antonevseev2708
    @antonevseev2708 Před 10 měsíci

    Awesome, brother! Please keep on sharing! Love your accent!

  • @user-lw1ux3vp6k
    @user-lw1ux3vp6k Před 8 měsíci

    Wow, It's amazing, bro! Спасибо, теперь я понял, что я делал не правильно, и понял как надо!

  • @varyag00
    @varyag00 Před 3 měsíci

    Hi Morris, I just wanted to say my sincere thank you for your outstanding tutorial -- it's saved me a lot of time and helped me better understand cluster networking. I appreciate your calm and evenly-paced dictation and I'll certainly stay tuned for more.
    I've now deployed metallb on my home cluster and honestly I'm just happy to stop port-forwarding every little service!

  • @rukzmrlonely
    @rukzmrlonely Před 4 měsíci

    Nice and crisp.
    I usually see training videos at 1.25 to 1.5 x speed. But As our freind Morris is so fast, this is the first time I slowed the video to .75 x😂. Solution worked for me

  • @suntenslp3315
    @suntenslp3315 Před 11 měsíci +3

    Hi Morris, your video made my day! I was stuck for a long time on how a load balancer assigns an external IP to my ingress controller. Most youtube resources just briefly mentioned this flow but without showing an actual example like you did. Your diagrams are really helpful to explain how things fit together.
    A suggestion if you don't mind - if you can share the commands and files you used on github, it will help beginners like me a lot.
    Hope to see more videos from you.

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci

      Hi suntenslp3315, thanks for watching I am very glad you liked the video. Thanks for the suggestion too, and I will definitely make it a goal to do better documentation for the videos.

    • @thegrimreaper156
      @thegrimreaper156 Před 10 měsíci

      Same!!! Thank you Morris.

  • @thadhinz8814
    @thadhinz8814 Před 7 měsíci

    Nice video! Very informative.

  • @mohamedumarali
    @mohamedumarali Před 9 měsíci

    Great explanation Morris!

  • @user-gd6ci8hy4e
    @user-gd6ci8hy4e Před rokem

    Amazing explanation, thank you!

  • @michaeltyiska
    @michaeltyiska Před 8 měsíci

    Great explanation. Just subbed!

  • @florin-marianhazi2143
    @florin-marianhazi2143 Před 17 dny

    Many thanks!
    You saved me a lot of time!!!

  • @st3ddyman
    @st3ddyman Před 11 měsíci

    Good, succinct information. Thanks for the video

  • @RobertoDMaggi
    @RobertoDMaggi Před 4 měsíci

    great job man! you made my day

  • @Kk-rl7nv
    @Kk-rl7nv Před 4 měsíci

    what a clear explanation in 10 minutes, can we get more videos with projects

  • @anas6435
    @anas6435 Před 5 měsíci

    Great explanation .. Thanks

  • @nagyjoco
    @nagyjoco Před 4 měsíci

    Great content! Subscribed.

  • @ilyasturan1234
    @ilyasturan1234 Před 5 měsíci

    Thank you. it was best video.

  • @user-yf1kh7gx6u
    @user-yf1kh7gx6u Před 3 měsíci

    great video mate

  • @gavnray
    @gavnray Před 11 měsíci

    Great explanation!

  • @wind1309
    @wind1309 Před 10 měsíci

    very nice presentation, subbed

  • @CorsisaTests
    @CorsisaTests Před měsícem

    Very helpful! thank you!

  • @Felipe-bi3mk
    @Felipe-bi3mk Před 5 měsíci

    nice vid, congrats

  • @nonenone6566
    @nonenone6566 Před 8 měsíci

    Clear explanations

  • @palanisamy-dl9qe
    @palanisamy-dl9qe Před měsícem

    Great video are you using Linux box or windows vm?

  • @harunafaruk2971
    @harunafaruk2971 Před 5 měsíci

    Thank you very much 🎉

  • @fvolpato
    @fvolpato Před měsícem

    very good!

  • @nareshh74
    @nareshh74 Před 8 měsíci

    thanks for the video Morris.
    I have a doubt - i see external Ip is assigned to the load balancer. but when i curl-ed it, it doesn't reach. how should i troubleshoot this?

  • @kashifmahmood8120
    @kashifmahmood8120 Před 7 měsíci

    Great explantion Morris. Will metalLB work in a hyper-scaler environment. And what if I need to have support for SCTP

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 7 měsíci

      Hi thanks a lot. I am not entirely sure as I have not yet tested it in such an environment. One thing to keep in mind though is that with this configuration mode MetalLB is working in Layer 2 mode and is doing a lot of stuff with ARP, so if your environment does not support ARP that might be an issue. MetalLB does also have a Layer 3 Mode where it uses BGP which you might want to check out as well.

  • @orideothuke1034
    @orideothuke1034 Před 10 měsíci

    Nice video. Please i'd like to ask a question. please how do we come about those range of IP addresses? i reckon public IP addresses are not free and that range could clash with some existing public IP somewhere. Thnx

  • @victorialopez471
    @victorialopez471 Před 9 měsíci

    Hi Morris, thank you for the excellent video!! The first one that finally explains Load Balancer + Ingress nginx + example to test locally for Bare metal. I followed the same installation as you but I'm not able to curl my service. Since the installation and services are set up the same, I wonder if it could be the network add-on that I'm using (Calico) seems like it requires additional IPPool manifest to be applied. Could you please share the network add-on you're using, and if any additional configuration was required? Much appreciated!

    • @victorialopez471
      @victorialopez471 Před 9 měsíci

      Forgot to add additional information in my setup:
      1 controller and 1 worker node (both set up in different computers)
      I'm using Kubernetes 1.28
      Calico v3.25.0

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 8 měsíci

      Hi thanks for watching, I really appreciate the support. I am using Calico as well which I set up as part of the Kubernetes install(you can checkout my other videos on setting up Kubernetes). I do have a default ippool(kubectl get ippool) configured and if you don't perhaps that is where the problem is. So might want to create an ippool. You might also want to try setting the ExternalTrafficPolicy on your metallb services to Cluster

  • @AlexKeySmith
    @AlexKeySmith Před rokem +1

    Great explanation of the relationship between nginx and ingress! Previously I'd missed the point that needed to set the service back to clusterip. Am I right in thinking nginx is implicitly using metallb? I've been struggling to conceptualise that after reading the documentation.

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před rokem +1

      Hi Alexander, thanks for watching. It is not absolutely necessary to revert the web app's service back to type ClusterIP in order for the web app to use NGINX Ingress. In such a scenario, access to the web app will be facilitated both through the external IP address(assigned by MetalLB) and the domain name which is pointing to NGINX Ingress' own LoadBalancer service external IP(also assigned by MetalLB). The reason for reverting back to ClusterIP is to conserve external IPs by freeing up the one used up by the web app.

    • @AlexKeySmith
      @AlexKeySmith Před rokem

      @@EngineeringWithMorris thanks for the fast response and clarification!

  • @MrJKetch
    @MrJKetch Před 8 dny

    Thank you

  • @lucatonnyr
    @lucatonnyr Před 5 měsíci +1

    A little question, how do you make the presentation?... Is dynamic, is cool!.

  • @abridevops-qr4pz
    @abridevops-qr4pz Před 11 měsíci

    I love your style of teaching. I have been having a hard time trying to install metalLB in my local k8s cluster. I used PROXMOX as my hypervisor for my bare metal. Do you have any ideas that can help me resolve this issue?

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci

      That depend on where the issue is, where do you seem to be stuck.

    • @abridevops-qr4pz
      @abridevops-qr4pz Před 11 měsíci

      @@EngineeringWithMorris when i try to install metalLB, i get crashloop Backoff for my speaker pods.

  • @iqbalibrahim4713
    @iqbalibrahim4713 Před 2 měsíci

    question, because there is ingress, should the load balancer pool need to be only one specific value? because all the other svc are using clusterIp

  • @DeepakPatel-yz1xx
    @DeepakPatel-yz1xx Před 11 měsíci

    Hi Morris, thanks for efforts in creating this tutorial. Would it be possible to show the same using CSP LB (AWS/AZure) to work with NGINX Ingress Controller in Kubernetes for any K8s running as Services (EKS/AKS) or K8s running on EC2 or nodes on CSP. Thanks in advance.

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci

      Hi, thanks for watching. I definitely do have some videos on cloud Kubernetes planned soon. Watch this space.

  • @user-xp6kb1rg1h
    @user-xp6kb1rg1h Před 6 měsíci +1

    how can I apply this tutorial to a cluster deployed in ec2 instance....I can access deployed app as load balancer but I cannot access it using ingress...what Ip should I give to cloudflare dns...?

  • @danielkirkland4439
    @danielkirkland4439 Před 7 měsíci +1

    Wonderful video! Thank you! I do have one question. Everything works great, but I am not clear on how I would be able to reach my services from a public URL or IP address. Without using an ingress and metallb, I would use nodeport. However, I am not seeing where or how to expose the ingress to internet connections. Any guidance would be most appreciated.

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 7 měsíci

      Hi, thanks for watching. You can use any IP address range with MetalLB even a publicly routable IP range as long as it is accessible on the node's ethernet segment. Another way to do it is to map an upstream public IP address range to the private range provisioned to MetalLB with port forwarding. This might require some extra configuration(probably through a custom mutating webhook admission controller) for the the public IP to show up as an externalIP on your LoadBalancer service.

    • @danielkirkland4439
      @danielkirkland4439 Před 7 měsíci

      Thanks I will give it a try. @@EngineeringWithMorris

  • @kevs3654
    @kevs3654 Před 7 měsíci

    sir what version of kubernetes are you using? 1.28?

  • @adityahpatel
    @adityahpatel Před 3 měsíci

    If your nodes have static ips, can't you attach external HaProxy load balancer instead of all this? .. where all Haproxy sends traffic to either node at say port 31111 (where you have the ingress-controller running)? Is this is a much simpler solution than metallb?

  • @adityahpatel
    @adityahpatel Před 3 měsíci

    Confusing - Does MetalLB load-balance across multiple nodes OR multiple services? If i have 5 raspberry Pis running Service#1 of type load balancer, does metalLB load balance across nodes?

  • @goodgameplays9571
    @goodgameplays9571 Před 3 měsíci

    Hello! Thank you all works well but i have a problem! when i try to access the link via my browser it doesn't work any idea ??

  • @krunal4baps
    @krunal4baps Před 26 dny

    Hi, I have pfsense router at home and K8S bare metal running on ubuntu with 2 master 2 worker setup.. I configured BGP on pfsense and I am hoping it's good, the logs are showing the assigned LoadBalancer IPs but somehow I can't resolve them on browser... I tried multiple times but something somewhere missing, any clue where should I be looking at? I have External IPs assigned correctly on get service output and on pfsense. It does show external ip in BGP logs that the next hop if worker nodes but when I put them in browser, it's bad gateway!!

  • @baileymiller5880
    @baileymiller5880 Před 5 měsíci

    This video makes it look so simple and I think I am really close but I am still having some trouble understanding this setup / it's not working on my small home cluster. I have 3 nodes, 1 control-plane and 2 rasp pi nodes. I followed all this same setup but nothing seems to be spinning up. For the IP pool, is that my home IP address or the IP address of the device on my network that is listening on ports 80,443? In my case only 1 device on my network has port forwarding setup for them (The control-plane node).

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 5 měsíci

      I am assuming you are able to reach your k8s cluster network, meaning you can ping either a control-plane node or a worker node from your machine. For example if your cluster network is 192.168.1.0/24 and your nodes use the range say from 192.168.1.10 - 192.168.1.20, then you should choose a metallb ip pool in the same network like say 192.168.1.30 - 192.168.1.50. Just ensure no other devices are using these reserved ips.

  • @nazil_kottakkal
    @nazil_kottakkal Před 9 měsíci

    iam anticipating a high volume of incoming traffic to my Kubernetes cluster through Ingress controller, and iam worried about potential damage to cluster due to the heavy load. i want to scale, unfortunately i have no idea about what will i scale ? ingress or node or control plane ? ingress controller where will be run ? please reply this

  • @bharadwaz7
    @bharadwaz7 Před 11 měsíci

    thank u subscribed

  • @tech-ness8989
    @tech-ness8989 Před rokem

    Hello Moris !
    Thank for you video !
    Can we know how to do those animations please ? we are doing content creation too and we really love your style

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před rokem +1

      Hi Tech-Ness, thanks for watching. I use Adobe After Effects for the animations.

  • @tynshjt
    @tynshjt Před měsícem

    Please help. I created the IP Pool and L2Advert. The pools all the nodes (masters and workers). Now my Kubernetes cluster is not accessible

  • @andherium
    @andherium Před 7 měsíci

    What happens if the node that was running the ingress controller pod goes down? You would need to change the host ip mapping to thew ip of the new node that runs the controller right?
    There should be a better way?

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 7 měsíci +1

      Hi, the MetalLB load balancer ips are not statically configured on any node, but are instead advertised out from an appropriate node. So in the event a node goes down the ip will simply be advertised through another node maintaining connectivity to your service. This is done automatically by MetalLB no need for manual intervention.

  • @armandofavelax
    @armandofavelax Před 10 měsíci

    Possible use only IP for multiples pods, see external? Nodeport no work Fine for redirect

  • @rileydavidjesus
    @rileydavidjesus Před 7 měsíci

    What if you want all services to share the same IP?

  • @gauravwadghule8085
    @gauravwadghule8085 Před 4 měsíci

    Hi which cluster version your have used
    Have you created your cluster with kubeadm then please share your config

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 4 měsíci

      Hi, I mostly use 1.27 and later. I have done a couple of videos on cluster setup you can check out below:
      K3S Lightweight Kubernetes Cluster
      Kubernetes at Home with Kubespray and Ansible

  • @martinotaco
    @martinotaco Před 3 měsíci

    Hi guys, I am looking for some clues. L2 is not working for me, curl with host ip and port works buy the ip assigned on for loadbalancer doesn’t

  • @debkr
    @debkr Před 7 měsíci

    👍

  • @hamzachakroun940
    @hamzachakroun940 Před 4 měsíci

    can i do this with a public ip @ please !!

  • @daturnerman76
    @daturnerman76 Před 6 měsíci

    Everything worked beautifully until I changed the deployment.yml file to remove the "Type: LoadBalancer" off. Now it won't connect to my container. I guess I'll have to plan around that limitation on my setup (RKE2). Thanks!

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 6 měsíci

      Hi, could be that RKE2 does not like it when you switch a service from type LB to clusterIP. You could try deleting the service and recreating it.

  • @oleggv5518
    @oleggv5518 Před 10 měsíci

    If the end user is in different subnet it won't work becaus he won't receive the ARP packets. That the scenario in production environment.

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 10 měsíci +1

      Hi, thanks for watching. The end user does not need to be on the same subnet as long a they have a route to that subnet. The default gateway on that subnet will receive the ARP messages and will be aware of all metallb assigned addresses.

  • @joseparra9006
    @joseparra9006 Před 9 měsíci +1

    How can I allow access only by domain and not by IP?

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 9 měsíci

      Hi, you need to set the service type to clusterIP, it will not be assigned a metallb IP. Then you can use ingress to access your service.

    • @victorialopez471
      @victorialopez471 Před 9 měsíci

      Hi @@EngineeringWithMorris I converted my service to CluterIP but it has an external IP address assigned from creation which matches the external IP address of the service/ingress-nginx-controller LoadBalancer. Comparing with the video, the ingress for the web-app doesn't have an IPAddress assign, it shows up empty. Which one's correct?
      When I do a curl to my host it doesn't show up anything.

  • @atpstealer
    @atpstealer Před 11 měsíci

    Hello! Very good video. But it will be better with examples. It's difficult to reproduce.
    Thank you anyway!!!!!!!!

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci +2

      Thank you for watching. Sorry about not including the instructions to the video before. I have added a link in the description to the GitHub project with all the manifests and setup instructions.

    • @atpstealer
      @atpstealer Před 11 měsíci

      @@EngineeringWithMorris thank you!

  • @hamzachakroun940
    @hamzachakroun940 Před 4 měsíci

    when you want to acces with url not curl you need bgp protocol !!

  • @Net_NOU
    @Net_NOU Před 7 dny

    Thank you, but you go too fast for me

  • @adityahpatel
    @adityahpatel Před 3 měsíci

    you have such nice content, but instead of explaining everything, you are just reading like a newsreader :-( Why are you rushing?

  • @muruligowda2985
    @muruligowda2985 Před 8 měsíci

    lv u from india

  • @amjads8971
    @amjads8971 Před 11 měsíci +1

    Great explanation but you should clearly state that this isn’t a production deployment plus metal lb shouldn’t be used in cloud but instead to be only leveraged in local or bare metal , unless I am mistaken. Please correct me

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci

      You are correct, the setup is for virtualisation environments where there are no cloud like load balancers to be leveraged like we have in AWS or GCP. For such virtualisation environments like Proxmox or VSphere MetalLB is a great solution and works perfectly well with home lab and production size clusters alike.

  • @mrunalmodi
    @mrunalmodi Před 11 měsíci

    I had to to use the below CLI to change the ingress-nginx-controller-admission type from ClusterIP to LoadBalancer so that Metallb could assign an external IP to the NGINX controller.
    kubectl patch service ingress-nginx-controller-admission -p '{"spec":{"type": "LoadBalancer", "externalTrafficPolicy":"Cluster"}}' -n ingress-nginx

    • @EngineeringWithMorris
      @EngineeringWithMorris  Před 11 měsíci

      Hi, thanks for watching. That’s is true! In some Kubernetes clusters you might need to set the external traffic policy to cluster for services of type LoadBalancer for ARP advertisement to work.