mirror of
https://github.com/coder/coder.git
synced 2025-07-09 11:45:56 +00:00
chore: upgrade tailscale to v1.46.1 (#8913)
This commit is contained in:
@ -21,6 +21,7 @@ import (
|
||||
"tailscale.com/types/key"
|
||||
|
||||
"cdr.dev/slog"
|
||||
"github.com/coder/coder/coderd/util/slice"
|
||||
)
|
||||
|
||||
// Coordinator exchanges nodes with agents to establish connections.
|
||||
@ -683,14 +684,14 @@ func HTTPDebugFromLocal(
|
||||
LastWriteAge: now.Sub(time.Unix(lastWrite, 0)).Round(time.Second),
|
||||
})
|
||||
}
|
||||
slices.SortFunc(agent.Connections, func(a, b *HTMLClient) bool {
|
||||
return a.Name < b.Name
|
||||
slices.SortFunc(agent.Connections, func(a, b *HTMLClient) int {
|
||||
return slice.Ascending(a.Name, b.Name)
|
||||
})
|
||||
|
||||
data.Agents = append(data.Agents, agent)
|
||||
}
|
||||
slices.SortFunc(data.Agents, func(a, b *HTMLAgent) bool {
|
||||
return a.Name < b.Name
|
||||
slices.SortFunc(data.Agents, func(a, b *HTMLAgent) int {
|
||||
return slice.Ascending(a.Name, b.Name)
|
||||
})
|
||||
|
||||
for agentID, conns := range agentToConnectionSocketsMap {
|
||||
@ -719,14 +720,14 @@ func HTTPDebugFromLocal(
|
||||
LastWriteAge: now.Sub(time.Unix(lastWrite, 0)).Round(time.Second),
|
||||
})
|
||||
}
|
||||
slices.SortFunc(agent.Connections, func(a, b *HTMLClient) bool {
|
||||
return a.Name < b.Name
|
||||
slices.SortFunc(agent.Connections, func(a, b *HTMLClient) int {
|
||||
return slice.Ascending(a.Name, b.Name)
|
||||
})
|
||||
|
||||
data.MissingAgents = append(data.MissingAgents, agent)
|
||||
}
|
||||
slices.SortFunc(data.MissingAgents, func(a, b *HTMLAgent) bool {
|
||||
return a.Name < b.Name
|
||||
slices.SortFunc(data.MissingAgents, func(a, b *HTMLAgent) int {
|
||||
return slice.Ascending(a.Name, b.Name)
|
||||
})
|
||||
|
||||
for id, node := range nodesMap {
|
||||
@ -737,8 +738,8 @@ func HTTPDebugFromLocal(
|
||||
Node: node,
|
||||
})
|
||||
}
|
||||
slices.SortFunc(data.Nodes, func(a, b *HTMLNode) bool {
|
||||
return a.Name+a.ID.String() < b.Name+b.ID.String()
|
||||
slices.SortFunc(data.Nodes, func(a, b *HTMLNode) int {
|
||||
return slice.Ascending(a.Name+a.ID.String(), b.Name+b.ID.String())
|
||||
})
|
||||
|
||||
return data
|
||||
|
Reference in New Issue
Block a user