Automate DNS updates

When a hostname is specified in the Kubernetes Ingress resource's rules, it can be used to automatically create DNS records for the given domain and App Gateway's IP address. To achieve this the ExternalDNS Kubernetes app is required. ExternalDNS in installable via a Helm chart. The following document provides a tutorial on setting up ExternalDNS with an Azure DNS.

Below is a sample Ingress resource, annotated with azure/application-gateway, which configures

apiVersion: extensions/v1beta1
kind: Ingress
  name: websocket-ingress
  namespace: alpha
  annotations: azure/application-gateway
    - host:
        - path: /
            serviceName: contoso-service
            servicePort: 80

Application Gateway Ingress Controller (AGIC) automatically recognizes the public IP address assigned to the Application Gateway it is associated with, and sets this IP ( on the Ingress resource as shown below:

$ kubectl get ingress -A
NAMESPACE             NAME                HOSTS                 ADDRESS   PORTS   AGE
alpha                 alpha-ingress   80      8m55s
beta                  beta-ingress   80      8m54s

Once the Ingresses contain both host and adrress, ExternalDNS will provision these to the DNS system it has been associated with and authorized for.