weaveworks / weave

Simple, resilient multi-host containers networking and more.
https://www.weave.works
Apache License 2.0
6.62k stars 670 forks source link

Allow changing NPC's metrics address from Weave's Kubernetes manifest's URL #3668

Open ricardbejarano opened 5 years ago

ricardbejarano commented 5 years ago

Here is the list of tunable parameters for Weave's Kubernetes manifest URL.

Among them, there's WEAVE_METRICS_ADDR, which sets Weave's Prometheus-style metrics endpoint's address, and defaults to 0.0.0.0:6782.

Based on this page in the docs, that is Weave's router's metrics endpoint; but there is a second endpoint, listening at 0.0.0.0:6781, for Weave's Network Policy Controller's metrics.

As far as I can tell, there is no way to set NPC's metrics listen address without manually editing the manifest.

I suggest adding a way of changing said parameter, preferably by using URL query string parameters like WEAVE_METRICS_ADDR and all the others.

murali-reddy commented 5 years ago

thanks for reporting. weave-npc binary already has couple of flags including metrics-addr. We just need a lunch script that can allow to customize.