DesktopECHO / Pi-Hole-for-WSL1

Ad-blocking DNS server for Windows • Unbound pre-configured • Deployment ready in minutes • Does not require hypervisor/docker
359 stars 54 forks source link

Stuck on "BITS Transfer" Connecting #105

Closed digitalcontemplation closed 1 year ago

digitalcontemplation commented 1 year ago

image image

It bounces between being primarily the blue highlighted text, and briefly the non- blue highlighted text.

barateza commented 1 year ago

UPDATE: I changed the cmdlet from Start-BitsTransfer to Invoke-WebRequest and apparently it worked. Still not sure why as Start-BitsTransfer does not have a built-in verbose mode and I am not well-versed on Powershell.


This is also happening to me. It seems that it gets stuck in the following line POWERSHELL.EXE -Command "Start-BitsTransfer -Source https://github.com/DesktopECHO/Pi-Hole-for-WSL1/archive/refs/heads/master.zip -Destination PH4WSL1.zip" >NUL 2>&1

That same URL above can be downloaded from a browser, but not via the script itself.

digitalcontemplation commented 1 year ago

@barateza What was it that you did, so that I could replicate it?

Edit: POWERSHELL.EXE -Command "Invoke-WebRequest -Uri 'https://github.com/DesktopECHO/Pi-Hole-for-WSL1/archive/refs/heads/master.zip' -OutFile 'PH4WSL1.zip'" > NUL 2>&1

Is indeed what seemed to work for me. -Yay, I did a small bit of code, with a big hint, haha!

barateza commented 1 year ago

@digitalcontemplation that'd be it! Still not sure why BITS wouldn't work - I myself thought that maybe GitHub was soft blocking me - but that doesn't make sense as the link can be downloaded from a browser.

DesktopECHO commented 1 year ago

@digitalcontemplation Thanks for the PR.
Added $ProgressPreference = 'SilentlyContinue' to speed up the download.