-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Fix openvsx-proxy metrics #11699
Fix openvsx-proxy metrics #11699
Conversation
@vulkoingim Instead of this change, I would suggest to add the kube-rbac-proxy to the statefulset Edit: the role bindings are already there |
2706efa
to
15b557d
Compare
@@ -132,7 +132,7 @@ func statefulset(ctx *common.RenderContext) ([]runtime.Object, error) { | |||
Name: "redis-data", | |||
MountPath: "/data", | |||
}}, | |||
}, | |||
}, *common.KubeRBACProxyContainer(ctx), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to understand how this works, we didn't have this param specified here before. How did this impact? Prometheus wasn't able to scrape the metrics at all? and why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Heya, there was a bit of a longer PR description (guess you can still see it in the history), but trimmed it, since I changed the solution on advise of Alejandro.
Long-story short is that there was a breaking change introduced in: 14095f4 It changed the prometheus listen address from any (0.0.0.0:9500
) to 127.0.0.1:9500
. Listening on 127.0.0.1 doesn't work because it is not accessible from outside of the container.
The rest of the services in the cluster use kube-rbac-proxy
to proxy the metrics endpoint, which this PR adds. The *common.KubeRBACProxyContainer(ctx)
is just a function that generates the container spec and we add it to the list of containers of the StatefulSet.
There's a longer discussion on Slack about that, if you are interested: https://gitpod.slack.com/archives/C01KGM9EBD4/p1658907591252089
Description
This adds the
kube-rbac-proxy
to theopenvxs-proxy
statefulset, exposing the metrics endpoint through it, so prometheus is able to scrape it correctly.How to test
Before and after updating the address
Release Notes
Werft options: