Hi together, I went go big or go home and had some...
# k3s
e
Hi together, I went go big or go home and had some issue understanding how to work with ingress. I deploy a few things with ansible, so I thought deploying via k3s-ansible is a good starting point for me. Everthings worked fine, so I fast forwarded to longhorn. Worked like a charm. Got into the documentation of longhorn and stranded at the exposing of the LonghornUI. And thats the point where I struggled: Do I have traefik running? It seemed so. Did I understand it until now? fo shizzle nope. I started reading here and there and got a grasp that I probably need an ingress controller, so I deployed it via
kubectl apply -f <https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v1.12.1/deploy/static/provider/baremetal/deploy.yaml>
which seems to be the latest release for me. That provided me the address of one of my control nodes via
kubectl -n longhorn-system get ingress
. But the curl results in an 404 page not found. which he also did before. So my issue I don't really know where to read next neither do I understand until now, what I am making wrong. My cluster looks like this: NAME STATUS ROLES AGE VERSION k3s-cn-01 Ready control-plane,etcd,master 92m v1.30.2+k3s1 k3s-cn-02 Ready control-plane,etcd,master 91m v1.30.2+k3s1 k3s-cn-03 Ready control-plane,etcd,master 91m v1.30.2+k3s1 k3s-wn-001 Ready <none> 90m v1.30.2+k3s1 k3s-wn-002 Ready <none> 90m v1.30.2+k3s1
c
traefik is an ingress controller. If you deployed ingress-nginx you now have two ingress controllers. Which is probably not what you want, and it is not going to work well for you.
e
So what had I missing instead: • Deployed via official k3s-ansible • Deployed longhorn via chart described in the docs • Tried to expose the longhorn UI described in the docs via basic auth ( I think here it went south) • Deployed nginx ingress (that was also faulty)
I looked into the docs after getting home. https://longhorn.io/docs/1.8.1/deploy/accessing-the-ui/longhorn-ingress/ Seems I did it wrong there (stating nginx). Is it enough to replace ingressClassName with traefik?
c
yes
e
Sometimes it is easy and just in front. Was also a bit misleaded by following statement: "This project is intended to provide a "vanilla" K3s install."
c
where did you find that statement?
e
Here: https://github.com/k3s-io/k3s-ansible at the bottom of the readme.
c
huh. well, a vanilla install of K3s comes with traefik, which you have… so that is accurate.
e
Yes was my own confusion creating the trouble. I look forward to see the result tomorrow, after configuring the dashboard correctly.
Thanks @creamy-pencil-82913 With Traefik it works now. Now I stuck with a stucked longhorn-manager CrashLoopBackOff. 👍