Migration assistance from Ingress NGINX to HAProxy Kubernetes Ingress Controller
Your toolkit for converting configuration and annotations from the retiring Ingress NGINX to HAProxy Kubernetes Ingress Controller. Get started fast by following our installation instructions and tutorials.
Annotation Mapping
Ingress NGINX Example
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: example-ingress
annotations:
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/rewrite-target: /
nginx.ingress.kubernetes.io/ssl-redirect: "true"
spec:
tls:
- hosts:
- my-app.tld
rules:
- host: example.com
http:
paths:
- path: /app
pathType: Prefix
backend:
service:
name: app-service
port:
number: 80
HAProxy Kubernetes Ingress Controller Example
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: example-ingress
annotations:
kubernetes.io/ingress.class: haproxy
haproxy.org/path-rewrite: /
haproxy.org/ssl-redirect: "true"
spec:
tls:
- hosts:
- my-app.tld
secretName: my-app-tls
rules:
- host: example.com
http:
paths:
- path: /app
pathType: Prefix
backend:
service:
name: app-service
port:
number: 80
Getting Started
Install HAProxy Kubernetes Ingress Controller using Helm
Add the HAProxy Kubernetes Ingress Controller Helm repository:
helm repo add haproxytech https://haproxytech.github.io/helm-charts helm repo updateInstall HAProxy Kubernetes Ingress Controller:
helm install haproxy-ingress haproxytech/kubernetes-ingress \ --namespace haproxy-controller \ --create-namespaceVerify the installation:
kubectl get pods -n haproxy-controller kubectl get svc -n haproxy-controllerCustom installation with values:
helm install haproxy-ingress haproxytech/kubernetes-ingress \ --namespace haproxy-controller \ --create-namespace \ --set controller.service.type=LoadBalancer \ --set controller.replicaCount=2Check the ingress class:
kubectl get ingressclass
Tutorials
Official tutorials for HAProxy Kubernetes Ingress Controller
For more information, see the complete documentation.
Define Ingress rules that state how traffic should be routed within your Kubernetes cluster.
The ingress controller load balances traffic across pods without further configuration, but you can customize its behavior.
HAProxy Kubernetes Ingress Controller can terminate SSL/TLS, handling encrypting traffic when it leaves and decrypting it when it enters.
Use the HAProxy Kubernetes Ingress Controller to load balance TCP services.