bloomberg / goldpinger

Debugging tool for Kubernetes which tests and displays connectivity between nodes in the cluster.
Apache License 2.0
2.53k stars 179 forks source link

Support multiple pod networks #104

Open Cerebus opened 3 years ago

Cerebus commented 3 years ago

Multiple CNIs can run in parallel, creating multiple data planes in a Kubernetes cluster. Goldfinger should allow me to ping over an arbitrary data plane.

It would seem that POD_IP is the place to set this, but when I set POD_IP for each goldpinger pod to an IP on an alternative dataplane, this setting is lost after discovery; goldpinger finds the peer pods but uses the primary data plane IP addresses.

Not all data planes are discoverable from the Pod API. E.g., Multus data plane specs are in Pod annotations. Meshnet-CNI specs data planes in a CRD that refers to a Pod resource by name.

seeker89 commented 3 years ago

While a little niche, I think that's a good idea. I wonder how we'd discover the alternative IPs, if they can't be provided by the Pod API (getting them from annotations would be straightforward).

I'd be happy to review a PR, let's just make sure we still default to the current behaviour.

Cerebus commented 3 years ago

Can someone better explain what POD_IP is supposed to do? That would be the place I'd start.

seeker89 commented 3 years ago

POD_IP is just a way for letting Goldpinger know its IP, to print better graphs.