-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
302 for all api calls using docker container #8
Comments
It's the default https redirect when going to the /v1 api. Is there a config setting to disable this? I also tried exposing the linstor-controller service via LoadBalancer but the automatic UI redirect is giving me an exception when I go to the load balancer IP port 3370. If I try to go to port 3371 on the LoadBalancer IP I get the self-signed cert but then an empty response. This even happens if I exec into the container and use
|
okay, so more playing around. I can pull the client certs from the csi-controller and talk to the controller with curl. So just need to work out how to use client certs when using the UI. |
Okay, I figured it out. I created a new Certificate for the ui and an ingress that uses the cert via The problem now is that I want to use rewrite on the ingress so that I don't want to expose the API via the ingress. For anyone searching here's the ingress: ---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: linstor-gui
annotations:
external-dns.alpha.kubernetes.io/target: "linstor.${SECRET_DOMAIN}"
nginx.ingress.kubernetes.io/proxy-ssl-secret: "piraeus-datastore/linstor-gui-tls"
nginx.ingress.kubernetes.io/backend-protocol: HTTPS
nginx.ingress.kubernetes.io/secure-backends: "true"
labels:
app.kubernetes.io/instance: linstor-gui
app.kubernetes.io/name: linstor-gui
spec:
ingressClassName: internal
rules:
- host: "linstor.${SECRET_DOMAIN}"
http:
paths:
- backend:
service:
name: linstor-controller
port:
number: 3371
path: /
pathType: Prefix And the cert: apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: linstor-gui-tls
spec:
commonName: linstor-gui-tls
dnsNames:
- linstor-gui-tls
issuerRef:
kind: Issuer
name: linstor-api-ca
secretName: linstor-gui-tls
usages:
- client auth |
I'm using piraeus-operator in kubernetes and have 1.8.2 deployed with some slight changes to the nginx config so the pod will run rootless. I can see the webpage and the metrics proxy location seems to be working okay but any calls to the api/v1 proxied location result in 302. Here are some container logs.
Here's my flux2 repo that deploys the container as a deployment in the same namespace as the controller.
https://github.com/brunnels/talos-cluster/blob/korg/kubernetes/apps/piraeus-datastore/linstor/gui/helmrelease.yaml
The container just built locally and pushed to my local repo.
Dashboard page looks mostly okay because it's mostly derived from the metrics api endpoint but no data gets loaded when clicking on anything because of the 302 errors.
The text was updated successfully, but these errors were encountered: