diff --git a/bootstrap/cluster/main.tf b/bootstrap/cluster/main.tf index 8743cd5..ac16bc2 100644 --- a/bootstrap/cluster/main.tf +++ b/bootstrap/cluster/main.tf @@ -991,7 +991,7 @@ if ! ssh -i "$ssh_key" -o BatchMode=yes -o ConnectTimeout=10 -o StrictHostKeyChe fi if ssh -i "$ssh_key" -o BatchMode=yes -o ConnectTimeout=10 -o StrictHostKeyChecking=accept-new "$ssh_target" \ - 'tailscale status --json >/dev/null 2>&1'; then + 'test -n "$(tailscale ip -4 2>/dev/null | head -n 1)"'; then ssh -i "$ssh_key" -o BatchMode=yes -o ConnectTimeout=10 -o StrictHostKeyChecking=accept-new "$ssh_target" \ "sudo tailscale set --accept-routes=$accept_routes" exit 0