Add configuration option to select iptables implementation
When running gocast in a container, the default iptables implementation may not match that used on the underlying host kernel. The current container uses the legacy iptables implementation and calls the `iptables` binary. This fails with exit code 3 when running on a host using the newer nftables implementation. The container already has `iptables-nft` binary included, so just needs a way to call this instead of the default `iptables` binary. This change implements a new `iptables_binary` config option, defaulting to `iptables`, and calls this when adding or removing NAT rules. Fixes #32 This change was written using AI LLM. Authored-By: Claude Code (Sonnet 4.5)
This commit is contained in:
@@ -15,7 +15,8 @@ type AgentConfig struct {
|
||||
CleanupTimer time.Duration `yaml:"cleanup_timer"`
|
||||
ConsulAddr string `yaml:"consul_addr"`
|
||||
ConsulQueryInterval time.Duration `yaml:"consul_query_interval"`
|
||||
ConsulToken string `yaml:"consul_token"`
|
||||
ConsulToken string `yaml:"consul_token"`
|
||||
IptablesBinary string `yaml:"iptables_binary"`
|
||||
}
|
||||
|
||||
type PeerConfig struct {
|
||||
|
||||
Reference in New Issue
Block a user