Cloud Deployments
Corporate users and applications reach private frontends through VPN, a private cloud connection, or an approved private access service. Public model calls use a separate outbound path.
Apply each cloud guide's private-ingress changes before deploying the AWS or GCP Terraform module. Helm uses your existing cloud infrastructure.
Choose a cloud
- Azure
- AWS
- GCP
Run LiteLLM on AKS with a private Application Gateway frontend, managed PostgreSQL and Redis, and private endpoints. The Azure architecture shows separate gateway, backend, and UI services.
Corporate clients use private network access to reach a private Application Gateway frontend. AKS and data stores stay private. NAT Gateway handles outbound provider requests.
Architecture details and references
- One Helm chart
- The litellm chart uses one image for all components. This layout uses the default monolith.enabled=false.
- Infrastructure you provide
- This example uses a customer-managed AKS cluster and virtual network. Provision Application Gateway, subnet policies, NAT Gateway, databases, private endpoints, and DNS separately. The LiteLLM Helm chart deploys the application workloads.
- Private Application Gateway
- Use a private-only frontend in a dedicated subnet delegated to Microsoft.Network/applicationGateways. Use AGIC v1.7 or later and appgw.ingress.kubernetes.io/use-private-ip: true. Allow corporate traffic through VPN, ExpressRoute, or an approved private access service. Configure private DNS. AGIC routes requests to pod private IPs. Set backend routes and health probes for your service layout.
- Public outbound traffic
- For your own virtual network, use AKS outboundType userAssignedNATGateway and associate NAT Gateway with the AKS subnet. NAT handles outbound public API calls. Private endpoint traffic stays private and bypasses NAT. NAT translates addresses. It does not inspect traffic.
- Private data connections
- This diagram uses PostgreSQL Private Link. Configure endpoint DNS and disable public access. Creating a private endpoint does not disable public access. Use the private PostgreSQL and Redis connections with TLS.
- Optional private model provider
- The dashed Azure OpenAI path needs its own private endpoint and private DNS records linked to the workload VNet. Create this endpoint separately. Public providers continue to use the separate NAT egress path.
Design references: LiteLLM chart and layouts (pinned) · Private Application Gateway deployment · AGIC private frontend · Application Gateway subnet requirements · Application Gateway Ingress Controller · AKS NAT Gateway options · PostgreSQL Private Link · Redis Private Link · Azure AI private network access
Use Terraform on ECS Fargate or Helm on EKS. The AWS architectures show private ALB ingress, private workloads, NAT egress, and optional Bedrock interface endpoints across two availability zones.
- Terraform on ECS Fargate
- Helm on EKS
Corporate clients use an internal ALB. Private workloads share database and cache endpoints. NAT serves outbound traffic only.
Architecture details and references
- One image
- The gateway, backend, UI, and migration job use the same image with a different startup argument for each component.
- Required module changes
- The module creates an internet-facing ALB. In your fork, set internal=true, select private ALB subnets, update the subnet precondition, and restrict port 443 to corporate source ranges. Remove public HTTP ingress. Add private access routes and private DNS. These are source changes, not module inputs.
- Base module resources
- The module creates one public and one private subnet for each supplied AZ, and one NAT gateway in the first public subnet. Supply at least two AZs. With an existing VPC, provide the subnets and routes yourself. Tasks, Aurora, and Redis share the private subnet set.
- Placement and availability
- The gateway defaults to two tasks. The backend and UI each default to one. Workload placements are illustrative. Data icons show shared endpoints, not AZ placement. Both AZs use the Aurora writer endpoint and Redis primary endpoint. Aurora has a reader, and Redis has one replica by default. The diagram omits replication paths. Add per-AZ NAT gateways and service replicas to meet your availability requirements.
- Security and egress
- Supply acm_certificate_arn for HTTPS. Allow corporate traffic only through the private access path. TLS terminates at the internal ALB. The task security group allows all TCP ports from the ALB security group. The diagram labels the target ports. Aurora allows 5432 and Redis allows 6379 from tasks only. Tasks have no public IP. External providers, public registries, and public AWS service endpoints use NAT. Create DNS records separately. Add WAF or ECR repositories if needed.
- Optional PrivateLink
- Create Bedrock interface endpoints separately. Use com.amazonaws.<region>.bedrock-runtime, private DNS, and endpoint security group ingress 443 from tasks. Grant Bedrock IAM permissions separately. The bedrock endpoint is for the control plane. To expose LiteLLM through PrivateLink, create a separate endpoint service.
Design references: Terraform network and security groups (pinned) · Terraform ALB routes and TLS (pinned) · Terraform ECS services (pinned) · Terraform defaults (pinned) · Internal load balancer scheme · AWS NAT gateway availability · Bedrock interface VPC endpoints
Corporate clients use an internal ALB. Private workloads share database and cache endpoints. NAT serves outbound traffic only.
Architecture details and references
- One Helm chart
- The litellm chart uses one image for all components. This layout uses the default monolith.enabled=false.
- Required infrastructure
- Helm deploys the LiteLLM workloads. Create private network access, the VPC, internal ALB, private EKS workers, Aurora, Redis, and per-AZ NAT gateways separately. Configure AWS Load Balancer Controller and Ingress for the selected service layout. Set alb.ingress.kubernetes.io/scheme: internal and select private ALB subnets. Set alb.ingress.kubernetes.io/target-type: ip to target pods directly. Instance mode targets NodePorts. Configure secrets and container log collection separately.
- Availability and access
- Spread replicas across AZs and set disruption budgets. Both AZs use the writer and primary endpoints by default. The diagram omits replication paths. Choose the database and cache replica layout you need. Allow ALB traffic to workload targets and allow database/cache traffic only from application security groups. Use a private EKS API endpoint.
- Optional PrivateLink
- The interface endpoints shown provide private Bedrock inference access through com.amazonaws.<region>.bedrock-runtime. Enable private DNS and allow HTTPS from workloads on the endpoint security group. Use pod identity and grant Bedrock permissions. Public providers and registries still need outbound access.
Design references: LiteLLM chart and layouts (pinned) · AWS EKS load balancing · EKS cluster endpoint access · Internal load balancer scheme · AWS NAT gateway availability · Bedrock interface VPC endpoints
Use Terraform on Cloud Run or Helm on GKE. The GCP architectures show internal load balancers, private network access, private database connections, and NAT egress.
- Terraform on Cloud Run
- Helm on GKE
Corporate clients use an internal load balancer. Cloud Run stays outside the customer VPC. Its connector reaches private data stores and Cloud NAT.
Architecture details and references
- Required module changes
- The module creates a global external load balancer. Replace it with regional INTERNAL_MANAGED resources, a private frontend address, and a REGIONAL_MANAGED_PROXY subnet. Keep the three serverless NEGs and path routes. Use regional TLS certificates. Set every Cloud Run service to INGRESS_TRAFFIC_INTERNAL_ONLY. The cloud guide lists the resource changes.
- Corporate access
- Connect corporate clients through Cloud VPN, Interconnect, or an approved private access service. Publish private DNS. Keep regional clients in the load balancer region or configure global access. Add identity checks and keep LiteLLM key permissions. Remove the public load balancer and unused Cloud Run domain mappings.
- One image
- The gateway, backend, UI, and migration job use the same image with a different startup argument for each component.
- Separate ingress and egress
- Serverless NEGs carry inbound requests through Google-managed routes. They do not use the VPC connector. Gateway, backend, and migration egress uses the connector. Cloud Run stays outside the customer VPC. Cloud SQL and Memorystore use Private Services Access to reach Google-managed producer networks.
- NAT egress changes
- The module does not create Cloud NAT or Cloud Router and sets PRIVATE_RANGES_ONLY. Create Cloud Router and Cloud NAT for the connector subnet. Set connector egress to ALL_TRAFFIC. Cloud Router configures NAT. Traffic does not pass through Cloud Router.
Design references: Module load balancer defaults · Module Cloud Run defaults · Internal load balancer with Cloud Run · Cloud Run ingress controls · Connector egress
Corporate clients use an internal load balancer. GKE workloads reach private data stores through peering. Cloud NAT handles public provider requests.
Architecture details and references
- Corporate access
- Use Cloud VPN, Interconnect, or an approved private access service and private DNS. Create a regional internal Application Load Balancer with a private frontend and proxy-only subnet. Restrict access to corporate clients. Configure global access if clients connect from another region.
- One Helm chart
- The litellm chart uses one image for all components. This layout uses monolith.enabled=false.
- GKE ingress
- Use internal GKE Ingress with the gce-internal class or the gke-l7-rilb GatewayClass. The controller creates zonal NEG backends. Allow the required proxy-only subnet and health-check traffic to pods. Keep nodes and the cluster endpoint private. Create these resources around the Helm workloads.
- Private node egress
- Configure Cloud NAT for the node and pod ranges that need public provider APIs or registries. Private Google Access serves supported Google APIs. Keep private database routes separate from NAT.
- Terraform data stores
- Set create_runtime=false to create data stores with the Google module. This skips Cloud Run, its load balancer, VPC connector, and migration job. Create GKE and configure its network separately.
Design references: LiteLLM chart and layouts · GKE internal Ingress · GKE Gateway deployment · Internal load balancer client access · Private Services Access · Terraform data stores
Deployment layout
One Docker image serves every component. One Helm chart supports both layouts. Terraform deploys separate services.
| Layout | What runs | Helm value |
|---|---|---|
| Single service | Inference, management APIs, and Admin UI together on port 4000. | monolith.enabled: true |
| Separate services (default) | Gateway on 4000, backend on 4001, and UI on 3000 scale independently. | monolith.enabled: false |