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

Tweak some settings for better Prometheus metrics access. #160

Merged
merged 1 commit into from Mar 8, 2018

Conversation

mattmoyer
Copy link
Member

@mattmoyer mattmoyer commented Mar 7, 2018

These are essentially the changes documented in kube-prometheus-on-kubeadm.md. They enable Prometheus running in Kubernetes to scrape container-level metrics from each Kubelet (authenticating with a ServiceAccount token) and to scrape metrics from kube-controller-manager and kube-scheduler (anonymously).

These have some tradeoffs that we should discuss. The kube-controller-manager and kube-scheduler --address changes mean that they will expose metrics over these endpoints to the whole cluster.

These metrics aren't super sensitive but they do give away some context about where the cluster is running, the versions of the components, and some high level picture of what's running in the cluster. I think this is acceptable for most use cases where the Quick Start is appropriate today.

There is recent work upstream (kubernetes/kubernetes#59582) that will add authentication options for these endpoints.

Update

I dropped the --address changes and left only the Kubelet authentication flag change.

Copy link
Contributor

@detiber detiber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see any issues with the changes to enable the kubelet metrics endpoint out of the box, but I think I would prefer if we held off on the changes to support the Controller Manager and Scheduler until auth support is in place.

controllerManagerExtraArgs:
address: 0.0.0.0
schedulerExtraArgs:
address: 0.0.0.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Opening up the metrics endpoints without authentication for these makes me a bit uneasy. I think I would prefer if we held off on these updates until the auth changes land upstream.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's fine. I took this change out and left only the kubelet change for now.

@mattmoyer
Copy link
Member Author

@detiber updated, PTAL.

Copy link
Contributor

@detiber detiber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mattmoyer mattmoyer merged commit f5b5478 into heptio:master Mar 8, 2018
@mattmoyer mattmoyer deleted the better-metrics-access branch March 8, 2018 17:15
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

Successfully merging this pull request may close these issues.

None yet

2 participants