kube-gen
kube-gen copied to clipboard
Added -node-envvar to watch pods on a specific node
When deployed as a daemonset, any pod event that happens will trigger all the kube-gen instances to load all pods. This becomes very expensive in a large cluster. The -node-envvar argument allows kube-gen to watch and load pods only on a specific/local node defined by this environment variable.
NOTES:
- We can't use the node name directly in the cli argument because at the deployment time, we don't know on which node kube-gen will land. So instead, we use environment variable that can be injected using kubernetes downward API.
@kylemcc ... if you can review this PR after the holiday that will be great ... thanks and happy holiday ...
@kylemcc ... ping
Sorry @panaji! Been busy with work. I will try to take a look at this tonight or tomorrow