The problem: it's hard to implement good monitoring in DBaaS with pmm-agent listening on 127.0.0.1 only.
Proposed solution: allow to specify alternative listening address, including "all addresses" option.
We would like to use liveness probes for pmm-agent like that one:
livenessProbe: httpGet: port: 7777 path: /local/Status timeoutSeconds: 2 initialDelaySeconds: 30 periodSeconds: 10 failureThreshold: 3
But that's not currently possible due to pmm-agent listening on 127.0.0.1, not on all network interfaces.
There should be a flag / configuration field / environment variable --listen-address / listen-address / PMM_AGENT_LISTEN_ADDRESS to allow one to specify network interface to listen to, or "0.0.0.0" to listen on all network interfaces. "127.0.0.1" should stay as a default value.
- without this flag, pmm-agent should work as before, and local API should be available only on 127.0.0.1;
- with this flag, pmm-agent's local API should be available on that IP address;
- in particular, using 0.0.0.0 should make this API available on all IP addresses.