diff --git a/peer/on_tick.go b/peer/on_tick.go index e9a6b58..c13e45a 100644 --- a/peer/on_tick.go +++ b/peer/on_tick.go @@ -22,6 +22,12 @@ func (a *App) onTick() { continue } p.wgPeer = wgPeer + if a.isPublic && !p.IsPublic { + if ep := p.WGEndpoint(); ep != p.EndpointV4 { + log.Printf("Client %s %s endpoint: %s -> %s", p.Name, p.VPNIP, p.EndpointV4, ep) + p.EndpointV4 = ep + } + } // Send pings to peers where we're the client. if p.Role == control.Client {