fix(firewall): iptables list uses -n flag for testing iptables path (#2574)

Signed-off-by: Jean-Francois Roy <jf@devklog.net>
This commit is contained in:
Jean-François Roy
2024-11-15 07:47:08 -08:00
committed by GitHub
parent f9bdb219d0
commit 36bb368cad

View File

@@ -92,7 +92,7 @@ func testIptablesPath(ctx context.Context, path string,
// Set policy as the existing policy so no mutation is done.
// This is an extra check for some buggy kernels where setting the policy
// does not work.
cmd = exec.CommandContext(ctx, path, "-L", "INPUT")
cmd = exec.CommandContext(ctx, path, "-nL", "INPUT")
output, err = runner.Run(cmd)
if err != nil {
unsupportedMessage = fmt.Sprintf("%s (%s)", output, err)