Bound the two tailscale lookups that were missed when the others were
This commit is contained in:
@@ -910,8 +910,12 @@ resolve_remote_ip() {
|
||||
local attempts=3
|
||||
|
||||
for ((i=1; i<=attempts; i++)); do
|
||||
# Direct lookup — works when MagicDNS short-name resolution is active
|
||||
REMOTE_SERVER=$(tailscale ip -4 "$ts_name" 2>/dev/null)
|
||||
# Direct lookup — works when MagicDNS short-name resolution is active.
|
||||
# Bounded, because it is not active here: the two hosts sit on separate tailnets, so
|
||||
# this call cannot succeed and blocks ~5s before giving up, while the status fallback
|
||||
# below answers in milliseconds. resolve_tailscale_ip() was bounded for this reason;
|
||||
# this function has the same lookup and was missed.
|
||||
REMOTE_SERVER=$(timeout 2 tailscale ip -4 "$ts_name" 2>/dev/null)
|
||||
|
||||
# Fallback — parse tailscale status for FQDN entries (e.g. hostname.tailXXXX.ts.net)
|
||||
if [[ -z "$REMOTE_SERVER" ]]; then
|
||||
|
||||
Reference in New Issue
Block a user