Feature: NET_ADMIN tip on routing permission error
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
|||||||
"net/http"
|
"net/http"
|
||||||
nativeos "os"
|
nativeos "os"
|
||||||
"os/signal"
|
"os/signal"
|
||||||
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
"syscall"
|
"syscall"
|
||||||
"time"
|
"time"
|
||||||
@@ -209,6 +210,9 @@ func _main(ctx context.Context, buildInfo models.BuildInformation,
|
|||||||
firewallConf.SetNetworkInformation(defaultInterface, defaultGateway, localNetworks, defaultIP)
|
firewallConf.SetNetworkInformation(defaultInterface, defaultGateway, localNetworks, defaultIP)
|
||||||
|
|
||||||
if err := routingConf.Setup(); err != nil {
|
if err := routingConf.Setup(); err != nil {
|
||||||
|
if strings.Contains(err.Error(), "operation not permitted") {
|
||||||
|
logger.Warn("💡 Tip: Are you passing NET_ADMIN capability to gluetun?")
|
||||||
|
}
|
||||||
return fmt.Errorf("%w: %s", errSetupRouting, err)
|
return fmt.Errorf("%w: %s", errSetupRouting, err)
|
||||||
}
|
}
|
||||||
defer func() {
|
defer func() {
|
||||||
|
|||||||
Reference in New Issue
Block a user