feat(vpn): rotate filtered servers on internal vpn restarts

- Fix #290
This commit is contained in:
Quentin McGaw
2026-05-04 03:28:48 +00:00
parent 4b819b4dbb
commit fed09562e5
57 changed files with 345 additions and 220 deletions
+3 -3
View File
@@ -2,7 +2,6 @@ package utils
import (
"fmt"
"math/rand"
"github.com/qdm12/gluetun/internal/configuration/settings"
"github.com/qdm12/gluetun/internal/constants/vpn"
@@ -35,7 +34,8 @@ func GetConnection(provider string,
selection settings.ServerSelection,
defaults ConnectionDefaults,
ipv6Supported bool,
randSource rand.Source) (
connPicker *ConnectionPicker,
) (
connection models.Connection, err error,
) {
servers, err := storage.FilterServers(provider, selection)
@@ -75,5 +75,5 @@ func GetConnection(provider string,
}
}
return pickConnection(connections, selection, randSource)
return pickConnection(connections, selection, connPicker)
}