When your SaaS platform is growing so fast that AWS limits become your biggest enemy, it's time to think outside the box.
8/12/2025 • Jainsi

Picture this: Your AI-powered website creation platform is absolutely crushing it. New customers are signing up daily, each bringing their own custom domains. Your infrastructure team is celebrating the growth, but there's a storm brewing on the horizon.
Then it hits you like a brick wall – AWS Application Load Balancer's 100 host-header rule limit.
Suddenly, your infrastructure that seemed so robust is now the bottleneck preventing you from onboarding new customers. Sound familiar? This is exactly what happened to one of our clients, and how we transformed their entire hosting architecture to break free from these limitations.
Let's be honest – the traditional setup seemed logical at first:
| Customer Domain → Route53 → ALB → EC2 Instances |
|---|
Simple, straightforward, and... completely unsustainable.
🔒 SSL Certificate Hell Every new domain meant manually provisioning SSL certificates. Our client's ops team was spending hours each week just getting certificates set up, renewed, and managed. It was like having a full-time job just for SSL babysitting.
📊 The Dreaded 100-Rule Limit AWS ALB's hard limit of 100 host-based routing rules per listener became our arch-nemesis. It's like being told you can only have 100 customers – not exactly the scaling story you want to tell your investors.
⚙️ Manual Everything Adding a new domain required infrastructure changes, manual certificate setup, and routing configuration. What should take minutes was taking hours, and every step was a potential point of failure.
💸 Operational Overhead Through the Roof Managing EC2 instances, tracking certificate expiration dates, and manually configuring routes for hundreds of domains? Our client's team was drowning in operational tasks instead of focusing on product innovation.
After analyzing the constraints and future growth projections, we realized we needed to completely reimagine the architecture. The solution? Kong Gateway combined with modern AWS services to create a truly cloud-native, infinitely scalable hosting platform.
🚀 Kong Gateway as the Traffic Orchestrator
We deployed Kong Gateway 3.9.1 on AWS ECS with awsvpc mode for maximum security and network isolation. But here's where it gets interesting – Kong doesn't have ALB's arbitrary 100-rule limitation. We can route traffic for thousands of domains through a single Kong instance.
The game-changer? Kong's ACME plugin automatically handles SSL certificate issuance and renewal through Let's Encrypt. No more 3 AM certificate expiration alerts!
🌍 Global Performance with AWS Global Accelerator
We didn't stop at just solving the scaling problem. Customer experience matters, so we implemented:
This setup ensures your customers get blazing-fast performance regardless of their location.
🔍 Dynamic Service Discovery with AWS Cloud Map
Here's where the architecture gets really elegant:
No more manual routing configurations. The system self-organizes!
🤖 Full Automation with AWS Lambda
The crown jewel of our solution is the serverless automation workflow. When a new domain needs to be provisioned, our Lambda function receives a payload like this:
{
"ecs_service_name": "customer-website-123",
"subdomain": "mycoolsite",
"container_image": "nginx:latest",
"container_port": 80,
"cpu": 256,
"memory": 1024,
"envs": [],
"domain": "test.domain"
}// Automated workflow steps
1. Parse payload (subdomain: "mycoolsite", domain: "virtues.agency")
2. Create ECS service with specified resources (256 CPU, 1024 MB memory)
3. Deploy container image with environment variables
4. Register service with Cloud Map for discovery
5. Create Kong service and route for "mycoolsite.virtues.agency"
6. ACME plugin automatically provisions SSL certificate
7. Customer site is live in < 5 minutes

Scalability Beyond ALB Limits
We eliminated the 100-domain bottleneck and can now support up to 5,000 domains per ECS cluster, with multi-cluster strategies for unlimited growth.
⚡ Lightning-Fast Provisioning
New domains go from signup to live website in under 5 minutes, completely automated. No human intervention required.
🔐 Rock-Solid Security
Every domain gets automatic SSL certificates with auto-renewal. No more certificate-related outages or security warnings.
💰 Significant Cost Savings
Automation and optimized resource utilization reduced infrastructure costs by 40% while dramatically improving performance.
🎯 Team Focus Shift
The ops team went from fighting infrastructure fires to focusing on product innovation and customer experience.
Before we get too excited about "infinite" scaling, let's address the elephant in the room – ECS has limits too.
Current ECS Service Quotas (as of 2024)
ECS supports up to 5,000 services per cluster, which is a significant improvement from the original 1,000 limit. However, there's an important caveat: services configured to use ECS service discovery have a limit of 1,000 tasks per service due to AWS Cloud Map service quota limitations.
If you're hitting similar scaling walls with your multi-domain SaaS platform, you don't have to accept these limitations. Modern cloud-native architectures can solve problems that seemed impossible just a few years ago.
The key is to stop thinking about infrastructure as a collection of servers and start thinking about it as a programmable platform that adapts to your business needs.
Want to discuss how this architecture could work for your specific use case? Let's talk about transforming your infrastructure from a scaling bottleneck into a competitive advantage.
Related articles you might find interesting

Why platform teams are re-routing north-south traffic through the Kubernetes Gateway API, what HTTPRoute changes on the ground, and how to migrate without a big-bang rewrite.


Hassle-Free ECS: Terraform Automation + CI/CD Pipeline