mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2026-05-21 13:26:29 +03:00
Centralise platform defaults into the 'defaults' package
This commit is contained in:
@@ -12,17 +12,6 @@ import (
|
||||
water "github.com/yggdrasil-network/water"
|
||||
)
|
||||
|
||||
// Sane defaults for the Linux platform. The "default" options may be
|
||||
// may be replaced by the running configuration.
|
||||
func getDefaults() tunDefaultParameters {
|
||||
return tunDefaultParameters{
|
||||
maximumIfMTU: 65535,
|
||||
defaultIfMTU: 65535,
|
||||
defaultIfName: "auto",
|
||||
defaultIfTAPMode: false,
|
||||
}
|
||||
}
|
||||
|
||||
// Configures the TAP adapter with the correct IPv6 address and MTU.
|
||||
func (tun *tunDevice) setup(ifname string, iftapmode bool, addr string, mtu int) error {
|
||||
var config water.Config
|
||||
|
||||
Reference in New Issue
Block a user