mirror of
https://github.com/qdm12/gluetun.git
synced 2026-07-24 19:36:24 +02:00
chore(updater): move updater packages to pkg/updaters/<name>
This commit is contained in:
@@ -1,9 +1,8 @@
|
||||
package pmtud
|
||||
|
||||
import (
|
||||
"github.com/qdm12/gluetun/internal/constants"
|
||||
"github.com/qdm12/gluetun/internal/constants/vpn"
|
||||
pconstants "github.com/qdm12/gluetun/internal/pmtud/constants"
|
||||
"github.com/qdm12/gluetun/pkg/updaters/constants"
|
||||
)
|
||||
|
||||
// MaxTheoreticalVPNMTU returns the theoretical maximum MTU for a VPN tunnel
|
||||
@@ -27,9 +26,9 @@ func MaxTheoreticalVPNMTU(vpnType, network string, ipv6 bool) uint32 {
|
||||
panic("unknown network protocol: " + network)
|
||||
}
|
||||
switch vpnType {
|
||||
case vpn.Wireguard, vpn.AmneziaWg:
|
||||
case constants.Wireguard, constants.AmneziaWg:
|
||||
vpnLinkMTU -= pconstants.WireguardHeaderLength
|
||||
case vpn.OpenVPN:
|
||||
case constants.OpenVPN:
|
||||
vpnLinkMTU -= pconstants.OpenVPNHeaderMaxLength
|
||||
default:
|
||||
panic("unknown VPN type: " + vpnType)
|
||||
|
||||
Reference in New Issue
Block a user