Could it be an option to have the site generate a download link instead of automatically initiating the download on the machine that’s running the webbrowser?
Quite often the machine I want to run caddy on is headless so is different to the machine I’ve selected the install options/generated the package from and I find myself digging the download URL out of the browsers download section so I can then wget it on the actual machine I wanted caddy on