mirror of
https://github.com/tailscale/tailscale.git
synced 2025-02-22 12:58:37 +00:00
controlclient: use per-peer KeepAlive signal
Signed-off-by: David Crawshaw <crawshaw@tailscale.com>
This commit is contained in:
parent
290f83e9f6
commit
8712164a0a
@ -16,7 +16,6 @@ import (
|
|||||||
|
|
||||||
"github.com/tailscale/wireguard-go/wgcfg"
|
"github.com/tailscale/wireguard-go/wgcfg"
|
||||||
"tailscale.com/tailcfg"
|
"tailscale.com/tailcfg"
|
||||||
"tailscale.com/version"
|
|
||||||
"tailscale.com/wgengine/filter"
|
"tailscale.com/wgengine/filter"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -328,8 +327,7 @@ func (nm *NetworkMap) _WireGuardConfig(uflags int, dnsOverride []wgcfg.IP, allEn
|
|||||||
aips = append(aips, aip)
|
aips = append(aips, aip)
|
||||||
}
|
}
|
||||||
fmt.Fprintf(buf, "AllowedIPs = %s\n", strings.Join(aips, ", "))
|
fmt.Fprintf(buf, "AllowedIPs = %s\n", strings.Join(aips, ", "))
|
||||||
doKeepAlives := !version.IsMobile()
|
if peer.KeepAlive {
|
||||||
if doKeepAlives {
|
|
||||||
fmt.Fprintf(buf, "PersistentKeepalive = 25\n")
|
fmt.Fprintf(buf, "PersistentKeepalive = 25\n")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user