mirror of
https://github.com/tailscale/tailscale.git
synced 2025-07-30 07:43:42 +00:00
cmd/natc: send TCP keepalives to upstreams
Idle connections may silently close, detect those closures with TCP keeliave. Updates tailscale/corp#25169 Signed-off-by: James Tucker <james@tailscale.com>
This commit is contained in:
parent
51adaec35a
commit
900b64403d
@ -475,7 +475,8 @@ func proxyTCPConn(c net.Conn, dest string) {
|
||||
},
|
||||
}
|
||||
p.AddRoute(addrPortStr, &tcpproxy.DialProxy{
|
||||
Addr: fmt.Sprintf("%s:%s", dest, port),
|
||||
Addr: fmt.Sprintf("%s:%s", dest, port),
|
||||
KeepAlivePeriod: time.Second,
|
||||
})
|
||||
p.Start()
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user