NET-528: add host static info to peer update (#2550)

* set isstatic field on peer update

* remove static check for peer port
This commit is contained in:
Abhishek K
2023-08-31 00:33:37 +05:30
committed by GitHub
parent a7fce5c3ba
commit 31fcc8cd6d
2 changed files with 3 additions and 0 deletions

View File

@@ -181,6 +181,7 @@ func GetPeerUpdateForHost(network string, host *models.Host, allNodes []models.N
hostPeerUpdate.HostNetworkInfo[peerHost.PublicKey.String()] = models.HostNetworkInfo{
Interfaces: peerHost.Interfaces,
ListenPort: peerPort,
IsStatic: peerHost.IsStatic,
}
nodePeer = peerConfig
} else {
@@ -191,6 +192,7 @@ func GetPeerUpdateForHost(network string, host *models.Host, allNodes []models.N
hostPeerUpdate.HostNetworkInfo[peerHost.PublicKey.String()] = models.HostNetworkInfo{
Interfaces: peerHost.Interfaces,
ListenPort: peerPort,
IsStatic: peerHost.IsStatic,
}
nodePeer = hostPeerUpdate.Peers[peerIndexMap[peerHost.PublicKey.String()]]
}