mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-07 10:40:25 +08:00
实现完整的集群、域名同步
This commit is contained in:
@@ -909,6 +909,10 @@ func (this *NodeService) FindEnabledNodeDNS(ctx context.Context, req *pb.FindEna
|
||||
}
|
||||
|
||||
dnsDomainId := int64(clusterDNS.DnsDomainId)
|
||||
dnsDomainName, err := models.SharedDNSDomainDAO.FindDNSDomainName(dnsDomainId)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
var route = ""
|
||||
if dnsDomainId > 0 {
|
||||
@@ -925,12 +929,13 @@ func (this *NodeService) FindEnabledNodeDNS(ctx context.Context, req *pb.FindEna
|
||||
|
||||
return &pb.FindEnabledNodeDNSResponse{
|
||||
Node: &pb.NodeDNSInfo{
|
||||
Id: int64(node.Id),
|
||||
Name: node.Name,
|
||||
IpAddr: ipAddr,
|
||||
Route: route,
|
||||
ClusterId: clusterId,
|
||||
DnsDomainId: dnsDomainId,
|
||||
Id: int64(node.Id),
|
||||
Name: node.Name,
|
||||
IpAddr: ipAddr,
|
||||
Route: route,
|
||||
ClusterId: clusterId,
|
||||
DnsDomainId: dnsDomainId,
|
||||
DnsDomainName: dnsDomainName,
|
||||
},
|
||||
}, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user