Skip to content
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

kube-oidc-proxy-orchestra pod died because the TLS secret is missing #73

Open
droslean opened this issue Apr 4, 2023 · 6 comments
Open

Comments

@droslean
Copy link

droslean commented Apr 4, 2023

  Warning  FailedMount  93s (x45 over 76m)  kubelet  MountVolume.SetUp failed for volume "kube-oidc-proxy-tls" : secret "unison-tls" not found

I am unsure if I remember correctly what is creating that secret, but I definitely don't understand how that secret got deleted or never existed.

@mlbiam
Copy link
Contributor

mlbiam commented Apr 4, 2023

The unison-tls Secret is created by the operator. It's the internal certificate used to secure communications between the ingress controller and OpenUnison&kube-oidc-proxy. If you "touch" the openunison orchestra object by adding an annotaion:

kubectl delete pods -l app=openunison-operator -n openunison
kubectl patch openunison orchestra -p '{"spec": {"template":{"metadata":{"annotations":{"force-update":"now"}}}} }'

The first command is so there's a clean set of logs for the operator in case the Secret doesn't get regenerated. The second command will trigger the operator to redeploy openunison, including generating any missing Secrets. If all goes well, both OpenUnison and kube-oidc-proxy should be all set.

@droslean
Copy link
Author

droslean commented Apr 4, 2023

@mlbiam spec.template.metadata.annotations on openunison resource doesn't exist.

Also the command generates error:

$ kubectl patch openunison orchestra -p '{"spec": {"template":{"metadata":{"annotations":{"force-update":"now"}}}} }'
Error from server (UnsupportedMediaType): the body of the request was in an unknown format - accepted media types include: application/json-patch+json, application/merge-patch+json, application/apply-patch+yaml

@droslean
Copy link
Author

droslean commented Apr 4, 2023

@mlbiam I changed the metadata.annotations and it worked.

@mlbiam
Copy link
Contributor

mlbiam commented Apr 4, 2023

sorry, i copied&pasted too quick

@droslean
Copy link
Author

droslean commented Apr 4, 2023

How can we make sure that this won't happen again?

@mlbiam
Copy link
Contributor

mlbiam commented Apr 4, 2023

There's a known issue with the older versions of the cert-checker job that we fixed, so making sure you're on the latest charts is important. We're also simplifying the operator (and making it much smaller) to minimize issues like this happening in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants