Преглед изворни кода

Merge branch 'feature_host_relay' of https://github.com/gravitl/netmaker into feature_host_metrics

Abhishek Kondur пре 2 година
родитељ
комит
f6741cc7d6
1 измењених фајлова са 4 додато и 1 уклоњено
  1. 4 1
      models/api_host.go

+ 4 - 1
models/api_host.go

@@ -96,7 +96,10 @@ func (a *ApiHost) ConvertAPIHostToNMHost(currentHost *Host) *Host {
 	h.Nodes = currentHost.Nodes
 	h.Nodes = currentHost.Nodes
 	h.TrafficKeyPublic = currentHost.TrafficKeyPublic
 	h.TrafficKeyPublic = currentHost.TrafficKeyPublic
 	h.OS = currentHost.OS
 	h.OS = currentHost.OS
-
+	h.RelayedBy = a.RelayedBy
+	h.RelayedHosts = a.RelayedHosts
+	h.IsRelay = a.IsRelay
+	h.IsRelayed = a.IsRelayed
 	if len(a.LocalRange) > 0 {
 	if len(a.LocalRange) > 0 {
 		_, localRange, err := net.ParseCIDR(a.LocalRange)
 		_, localRange, err := net.ParseCIDR(a.LocalRange)
 		if err == nil {
 		if err == nil {