I have used the official Kubernetes-dashboard and was trying to setup an ingress for the dashboard. I have tried to put the ingress into the Kubernetes-dashboard namespace, but the ingress won't show up when I tried kubectl get all -n kubernetes-dashboard
. I could still describe the ingress in the same namespace using kubectl get ingress -n kubernetes-dashboard
, but the annotations shown up <none>
. Can anyone please help me?
Here is my yaml file for the ingress:
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: dashborad-ingress
namespace: kubernetes-dashboard
spec:
rules:
- host: dashboard.com
http:
paths:
- path: /testpath
pathType: Prefix
backend:
service:
name: kubernetes-dashboard
port:
number: 443
And the output of kubectl desribe ingress -n kubernetes-dashboard
Name: dashborad-ingress
Namespace: kubernetes-dashboard
Address: 192.168.49.2
Default backend: default-http-backend:80 (<error: endpoints "default-http-backend" not found>)
Rules:
Host Path Backends
---- ---- --------
dashboard.com
kubernetes-dashboard:443 (172.17.0.6:8443)
Annotations: <none>
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Sync 4m7s (x5 over 24m) nginx-ingress-controller Scheduled for sync
Any helps would be appreciated.