TLS Support on Azure App Gateway as Ingress Controller (AGIC) over Private IP

I have an Azure Kubernetes Service (AKS) cluster that I built using Terraform. As part of the provisioning of the cluster, I also created the App Gateway as part of and integrated with the cluster.

resource "azurerm_kubernetes_cluster" "aks" {
  name                                           = var.aks_cluster_name
  resource_group_name            = var.aks_rg
  location                                       = var.aks_location
  dns_prefix                                     = var.dns_prefix
  automatic_channel_upgrade = var.upgrade_channel
  private_dns_zone_id                    = data.azurerm_private_dns_zone.akszone.id
  private_cluster_enabled                = true
  oidc_issuer_enabled                    = true
  workload_identity_enabled     = true
  local_account_disabled          = true
  azure_policy_enabled                   = true
 
  ingress_application_gateway {
    gateway_name = "${var.aks_cluster_name}-agw"
    subnet_id  = data.azurerm_subnet.AppGw.id
  }
.
..
...
} 
 

The Azure subscriptions and vnet design follow the hub-and-spoke model with a user-defined route (UDR) to redirect traffic to the virtual network appliances (NAV) in the HUB subscription. The AKS resides in the DEV subscription and the AKS network environment is configured to use Azure CNI (not CNI Overlay). The App Gateway is configured with both a public and private IP address. Here is my YAML:

For HTTP:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: demo3
  namespace: dev-demos
spec:
  replicas: 1
  selector:
    matchLabels:
      app: demo3
  template:
    metadata:
      labels:
        app: demo3
    spec:
      containers:
      - name: demo3
        image: mcr.microsoft.com/azuredocs/aks-helloworld:v1
        ports:
        - containerPort: 80
        env:
        - name: TITLE
          value: "Welcome to Azure Kubernetes Service (AKS) - Demo3"
        resources:
          requests:
            memory: "128Mi"
            cpu: "250m"
          limits:
            memory: "256Mi"
            cpu: "500m" 
 
---
apiVersion: v1
kind: Service
metadata:
  name: demo3
  namespace: dev-demos
spec:
  type: ClusterIP
  ports:
  - port: 80
  selector:
app: demo3
 
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: ingress
  namespace: dev-demos
  annotations:
    appgw.ingress.kubernetes.io/use-private-ip: "false"
spec:
  ingressClassName: azure-application-gateway
  rules:
  - host: testhost.contoso.com
    http:
      paths:
      - path: /demo3
        pathType: Exact
        backend:
          service:
            name: demo3
            port:
              number: 80

This works when a client request is sent to http://testhost.contoso.com. I have another similar YAML to enable TLS over the public IP and that also works with no issue.

When I flipped the annotation to use-private-ip: “true” and attempted to browse the service from an internal network, I couldn’t get any response from the App Gateway at all at the TCP level. When viewed using network trace, I can only see the client requests and no response from the App Gateway to the request. I first thought perhaps it was the UDR that redirected my traffic to the NVA, but then I realized that was not the case because the UDR is not associated with the AppGateway subnet. On the Network Security Rule (NSG) front, I have 2 TCP-allowed rules configured to allow inbound from ANY to the PUBLIC and PRIVATE IP of the App Gateway.

What am I missing?

We’ve been on the line with Microsoft Support for three weeks now, used LLMs, and talked to everyone we can in our organization for help but are unable to resolve this problem. Any suggestion will be helpful.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật