cloudnativelabs / kube-router

Kube-router, a turnkey solution for Kubernetes networking.
https://kube-router.io
Apache License 2.0
2.33k stars 471 forks source link

fix(rt_tables): add path fallback logic #1629

Closed aauren closed 8 months ago

aauren commented 8 months ago

@mrueg

Ever since version v6.5.0 of iproute2, iproute2 no longer automatically creates the /etc/iproute2 files, instead preferring to add files to /usr/lib/iproute2 and then later on /usr/share/iproute2.

This adds fallback path matching to kube-router so that it can find /etc/iproute2/rt_tables wherever it is defined instead of just failing.

This also means people running kube-router in containers will need to change their mounts depending on where this file is located on their host OS. However, ensuring that this file is copied to /etc/iproute2 is a legitimate way to ensure that this is consistent across a fleet of multiple OS versions.