Skip to main content

Setting up Istio Gateway with AWS NLB (TLS terminated at NLB)

This guide demonstrates how to deploy a simple Nginx application in Kubernetes, enable Istio service mesh, and expose it externally using an Istio Gateway behind an AWS NLB with ACM TLS certificate.

1️⃣ Prerequisites

  • Kubernetes cluster running in AWS (EKS recommended).
  • Istio CLI installed (istioctl).
  • AWS CLI configured with appropriate IAM permissions for creating NLB and attaching ACM certificate.
  • ACM certificate already issued in the region for your domain.

2️⃣ Step 1: Create Namespaces

Enable Istio sidecar injection for demo namespace:

3️⃣ Step 2: Install Istio

Check that Istio ingressgateway pods are running:

4️⃣ Step 3: Deploy Nginx Application

nginx-istio.yaml:
Apply:

5️⃣ Step 4: Create Istio Gateway

istioG-https.yaml:
Apply:

6️⃣ Step 5: Create VirtualService

istio-VS.yaml:
Apply:

7️⃣ Step 6: Update Istio IngressGateway Service with NLB

istioG-nlb.yaml:
Apply:
  • Note: NLB terminates TLS on 443, forwards HTTP to Istio ingressgateway port 8080.
  • Target group health check should be port 8080, path /healthz/ready.

8️⃣ Step 7: Test Locally

Port-forward to test HTTP routing:
  • Should return Nginx welcome page.
  • Do NOT use HTTPS locally — TLS is terminated at NLB only.

9️⃣ Step 8: Test via NLB

  • Copy the NLB DNS from kubectl get svc istio-ingressgateway -n istio-system.
  • Open browser:
  • Should show the Nginx page via HTTPS.

10️⃣ Common Issues and Fixes


11️⃣ Summary of Files


✅ Traffic Flow Diagram

  • NLB handles HTTPS.
  • Istio Gateway handles routing, retries, etc.
  • Nginx serves the application.

This setup is production-ready for TLS termination at NLB only while letting Istio manage all routing/traffic features internally.