aj-geddes avatar

Load Balancer Setup

This walks you through setting up load balancers like HAProxy and AWS ELB/ALB/NLB to spread traffic across multiple servers. You get reference guides for HAProxy config files, CloudFormation templates for AWS ALB, health check scripts, and monitoring setups. It covers the practical stuff: session persistence, SSL termination, health checks, and cross-region balancing. The best practices section is genuinely helpful, steering you away from common mistakes like skipping health checks or creating single points of failure. If you're moving beyond a single server or need failover that actually works, this gives you working configs and deployment patterns rather than just theory.

skills.sh installs
454
GitHub stars
379
last updated
Aug 21, 2026

Install

$ npx -y skills add aj-geddes/useful-ai-prompts --skill load-balancer-setup --agent claude-code

Installs into .claude/skills of the current project.

Files

Load Balancer Setup

Table of Contents

Overview

Deploy and configure load balancers to distribute traffic across multiple backend servers, ensuring high availability, fault tolerance, and optimal resource utilization across your infrastructure.

When to Use

  • Multi-server traffic distribution
  • High availability and failover
  • Session persistence and sticky sessions
  • Health checking and auto-recovery
  • SSL/TLS termination
  • Cross-region load balancing
  • API rate limiting at load balancer
  • DDoS mitigation

Quick Start

Minimal working example:

# /etc/haproxy/haproxy.cfg
global
    log stdout local0
    log stdout local1 notice
    maxconn 4096
    daemon

    # Security
    tune.ssl.default-dh-param 2048
    ssl-default-bind-ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256
    ssl-default-bind-options ssl-min-ver TLSv1.2

defaults
    log global
    mode http
    option httplog
    option denylogin
    option forwardfor
    option http-server-close

Sponsors

Details

Repository
github.com/aj-geddes/useful-ai-prompts
Categories
DevOps & CI/CD, AI & Agent Building, Release Management, Marketing & SEO, Cloud & Infrastructure
First seen
Jun 3, 2026

More from aj-geddes/useful-ai-prompts

All 258
1aj-geddes avataraws-rds-databaseaj-geddes/useful-ai-promptsDeploy and manage relational databases using RDS with Multi-AZ, read replicas, backups, and encryption. Use for PostgreSQL, MySQL, MariaDB, and Oracle.453skills.sh installs
2aj-geddes avatarlog-aggregationaj-geddes/useful-ai-promptsImplement centralized logging with ELK Stack, Loki, or Splunk for log collection, parsing, storage, and analysis across infrastructure.453skills.sh installs
3aj-geddes avatarsecrets-managementaj-geddes/useful-ai-promptsImplement secrets management with HashiCorp Vault, AWS Secrets Manager, or Kubernetes Secrets for secure credential storage and rotation.449skills.sh installs
4aj-geddes avatarcloud-cost-managementaj-geddes/useful-ai-promptsOptimize and manage cloud costs across AWS, Azure, and GCP using reserved instances, spot pricing, and cost monitoring tools.447skills.sh installs
5aj-geddes avatarcontainer-registry-managementaj-geddes/useful-ai-promptsManage container registries (Docker Hub, ECR, GCR) with image scanning, retention policies, and access control.444skills.sh installs
6secondsky avatarapp-store-deploymentsecondsky/claude-skillsPublishes mobile applications to iOS App Store and Google Play with code signing, versioning, and CI/CD automation. Use when preparing app releases, configuring437skills.sh installs