fix: update iptables binary paths to use /usr/sbin instead of /sbin
continuous-integration/drone/push Build is passing

Standardize iptables paths across firewall scripts and Go code to ensure compatibility with systems where iptables is located in /usr/sbin. This affects both legacy and non-legacy iptables binaries.
This commit is contained in:
gyurix
2026-06-15 16:34:24 +02:00
parent 2d6e22b9e6
commit 3172023254
3 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -173,7 +173,7 @@ pid, _ := dockerClient.GetContainerPID(ctx, containerName)
// 2. Execute iptables inside container namespace via nsenter
exec.Command("nsenter", "-t", fmt.Sprintf("%d", pid), "-n", "--",
"/sbin/iptables-legacy", "-t", "nat", "-I", "PREROUTING", ...)
"/usr/sbin/iptables-legacy", "-t", "nat", "-I", "PREROUTING", ...)
```
- `-t <pid>` — target the container's PID