Switch TacticalRMM download to WebClient for redirect handling

Invoke-WebRequest hangs on the TacticalRMM download URL (same redirect
issue previously fixed for RustDesk). Use WebClient.DownloadFile instead.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
uhlwoogi
2026-04-21 16:34:50 +00:00
co-authored by Claude Sonnet 4.6
parent 3ff00aca6d
commit d3844a857c
@@ -177,7 +177,7 @@ If (Get-Service $serviceName -ErrorAction SilentlyContinue) {
Try {
Write-Host "Downloading TacticalRMM agent..."
Invoke-WebRequest -Uri $downloadlink -OutFile "$OutPath\$output" -UseBasicParsing -ErrorAction Stop
(New-Object System.Net.WebClient).DownloadFile($downloadlink, "$OutPath\$output")
Write-Host "Download complete."
Start-Process -FilePath "$OutPath\$output" -ArgumentList '/VERYSILENT /SUPPRESSMSGBOXES' -Wait
Write-Host "Extracting..."