Ingress - Airflow
Exposing Airflow via Ingress enables external HTTP/HTTPS access to the cluster using a dedicated hostname.
Ingress vs Gateway API
TDPConfiguration.gateway.ingress and TDPConfiguration.gateway.gatewayApi are mutually exclusive. Enable only one of them.
Prerequisites
- Ingress Controller installed in the cluster (e.g. NGINX).
- DNS configured or an entry in
/etc/hostspointing to the external IP of the Ingress. - TLS certificates are optional.
Configuration example
TDPConfiguration:
gateway:
ingress:
enabled: true
ingress:
ingressClassName: <ingress-class>
hosts:
- host: airflow.tdp.local
paths:
- path: /
pathType: Prefix
tls: []
Replace <ingress-class> with the Ingress Controller name in your environment (check with kubectl get ingressclass).
Access
- Get the external IP of the Ingress Controller:
Terminal input
kubectl get svc -A -l app.kubernetes.io/name=ingress-nginx \
-o jsonpath='{.items[0].status.loadBalancer.ingress[0].ip}' - Add the hostname to DNS or to the
/etc/hostsfile:<INGRESS_IP> airflow.tdp.local - Access
http://airflow.tdp.local(orhttps://if TLS is configured).
Troubleshooting
| Problem | Cause | Solution |
|---|---|---|
| Ingress not created | TDPConfiguration.gateway.ingress.enabled: false or incorrect ingressClassName | Check both settings |
| Host not resolving | DNS or /etc/hosts not configured | Fix name resolution on the client |
| 502 Bad Gateway | Airflow pod not ready | Check kubectl get pods -n <namespace> |