kubernetes-sigs / ip-masq-agent

Manage IP masquerade on nodes
Apache License 2.0
217 stars 70 forks source link

Error: Unable to redirect iptables binaries in v2.9.2 #105

Closed bandesz closed 1 year ago

bandesz commented 1 year ago

What

I've tried to use the latest v2.9.2 image, but I get an error when the agent tries to execute iptables commands.

v.2.9.2 errors:

$ docker run -it --entrypoint "/usr/sbin/iptables" --rm registry.k8s.io/networking/ip-masq-agent:v2.9.2 --version
Unable to redirect iptables binaries. (Are you running in an unprivileged pod?)
ERROR: No valid subcommand given.
Valid subcommands:
[...]

Also tried with --priviliged, same result.

v2.9.0 works:

$ docker run -it --entrypoint "/usr/sbin/iptables" --rm registry.k8s.io/networking/ip-masq-agent:v2.9.0 --version
iptables v1.8.7 (nf_tables)
bandesz commented 1 year ago

Fixed by https://github.com/kubernetes-sigs/ip-masq-agent/pull/102, it works in the v2.9.3 image.