mirror of
https://github.com/tailscale/tailscale.git
synced 2024-11-25 19:15:34 +00:00
control/controlclient: don't use Node as value type
This commit is contained in:
parent
7caa288213
commit
073bb8de80
@ -18,7 +18,6 @@
|
|||||||
"net/http"
|
"net/http"
|
||||||
"os"
|
"os"
|
||||||
"runtime"
|
"runtime"
|
||||||
"strconv"
|
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
@ -564,14 +563,6 @@ func (c *Direct) PollNetMap(ctx context.Context, maxPolls int, cb func(*NetworkM
|
|||||||
Hostinfo: resp.Node.Hostinfo,
|
Hostinfo: resp.Node.Hostinfo,
|
||||||
PacketFilter: resp.PacketFilter,
|
PacketFilter: resp.PacketFilter,
|
||||||
}
|
}
|
||||||
// Temporary (2020-02-21) knob to force debug, during DERP testing:
|
|
||||||
if ok, _ := strconv.ParseBool(os.Getenv("DEBUG_FORCE_DERP")); ok {
|
|
||||||
c.logf("debug: adding DERP endpoints to all peers")
|
|
||||||
for i := range nm.Peers {
|
|
||||||
peer := &nm.Peers[i]
|
|
||||||
peer.Endpoints = append([]string{"127.3.3.40:1"}, peer.Endpoints...)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for _, profile := range resp.UserProfiles {
|
for _, profile := range resp.UserProfiles {
|
||||||
nm.UserProfiles[profile.ID] = profile
|
nm.UserProfiles[profile.ID] = profile
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,7 @@ type NetworkMap struct {
|
|||||||
Addresses []wgcfg.CIDR
|
Addresses []wgcfg.CIDR
|
||||||
LocalPort uint16 // used for debugging
|
LocalPort uint16 // used for debugging
|
||||||
MachineStatus tailcfg.MachineStatus
|
MachineStatus tailcfg.MachineStatus
|
||||||
Peers []tailcfg.Node
|
Peers []*tailcfg.Node
|
||||||
DNS []wgcfg.IP
|
DNS []wgcfg.IP
|
||||||
DNSDomains []string
|
DNSDomains []string
|
||||||
Hostinfo tailcfg.Hostinfo
|
Hostinfo tailcfg.Hostinfo
|
||||||
|
@ -404,8 +404,8 @@ type MapResponse struct {
|
|||||||
KeepAlive bool // if set, all other fields are ignored
|
KeepAlive bool // if set, all other fields are ignored
|
||||||
|
|
||||||
// Networking
|
// Networking
|
||||||
Node Node
|
Node *Node
|
||||||
Peers []Node
|
Peers []*Node
|
||||||
DNS []wgcfg.IP
|
DNS []wgcfg.IP
|
||||||
SearchPaths []string
|
SearchPaths []string
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user