Перейти к содержимому

I Built a Load Balancer on AWS from Scratch (Nginx + Terraform, Full Hands-On)

SADIQ ABDULRAHAMAN

0:00 / 0:00

I Built a Load Balancer on AWS from Scratch (Nginx + Terraform, Full Hands-On)

192 просмотра · 12 дн. назад
SADIQ ABDULRAHAMAN
13 подписчиков
192 просмотра · 12 дн. назад
Your app is slow, or one server goes down and your whole site goes with it. A load balancer fixes that. In this 1-hour hands-on project, we build one from scratch on AWS. You'll set up a public Nginx server that shares traffic between two private backend servers, using Terraform to build the whole infrastructure. By the end, you'll watch requests alternate between servers live, and see the site stay up when one goes down. What you'll build: VPC with public and private subnets (Terraform) Security groups that hide the backends from the internet An Nginx reverse proxy with a public IP Two Node.js backend servers with no public IP A load balancer using round-robin (and how to switch to least connections) A live trace showing which server answers each request Who this is for: beginners learning DevOps, developers moving into cloud, and anyone preparing for a DevOps interview. No advanced experience needed. Chapters: 0:00 Architecture explained simply 17:00 Writing the Terraform (VPC, subnets, security groups) 27:00 Launching the servers 30:00 Setting up nginx 32:40 Setting up the Node.js backends 42:40 Configuring Nginx as a reverse proxy 50:00 Turning it into a load balancer 54:00 Live demo: traffic switching between servers 56:00 Least connections and other methods 57:33 Take down one service and Recap Code and diagrams: https://github.com/Ramsoon/loadbalanc... Previous parts:    • proxy demo pt1   Subscribe and turn on notifications so you don't miss the next project. #devops #loadbalancer #nginx #terraform #aws