ingress.yaml with the following content:
2. Apply the manifest:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
ingress.yaml with the following content:
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: example-ingress
namespace: default
spec:
ingressClassName: nginx
rules:
- http:
paths:
- pathType: Prefix
path: /
backend:
service:
name: example-service
port:
number: 80
| Field | Description |
|---|---|
name | Name of the Ingress object |
namespace | Namespace where the target Service runs |
ingressClassName | Name of the IngressClass — nginx for the nginx controller |
path | URL path prefix to match incoming requests |
service.name | Name of the Service to route traffic to |
service.port.number | Port exposed by the target Service that receives incoming requests |
kubectl apply -f ingress.yaml
ingress.networking.k8s.io/example-ingress created
Was this page helpful?