mirror of
https://github.com/qdm12/gluetun.git
synced 2026-05-09 20:29:23 +02:00
Fallback to accepting only NEW output public traffic if conntrack netlink isn't supported
This commit is contained in:
@@ -69,6 +69,11 @@ func (c *Config) enable(ctx context.Context) (err error) {
|
||||
return err
|
||||
}
|
||||
|
||||
err = c.flushExistingConnections(ctx)
|
||||
if err != nil {
|
||||
return fmt.Errorf("flushing existing connections: %w", err)
|
||||
}
|
||||
|
||||
if err = c.impl.AcceptEstablishedRelatedTraffic(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -121,11 +126,6 @@ func (c *Config) enable(ctx context.Context) (err error) {
|
||||
return fmt.Errorf("running user defined post firewall rules: %w", err)
|
||||
}
|
||||
|
||||
err = c.netlinker.FlushConntrack()
|
||||
if err != nil {
|
||||
c.logger.Warn("flushing conntrack failed: " + err.Error())
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user