Add support for ELECTRON_BUILDER_BINARIES_CUSTOM_DIR
Currently it is impossible to customize the directory part of the URL when downloading winCodeSign-[version].7z for example
This line needs to be changed so we can specify a custom value from env instead of id:
https://github.com/develar/app-builder/blob/0bc38fb5e76c38ab24e36acf7a17887370e31fb4/pkg/download/tool.go#L63
The main electron-builder repo already supports ELECTRON_BUILDER_BINARIES_CUSTOM_DIR so why not use it here?
I agree, this will help teams who are trying to get it working while behind a corporate firewall which presents loads of network connectivity restrictions.
I have an offline copy of winCodeSign-2.6.0.7z, but I'm not able to point app-builder-bin towards this because it's hardcoded to download from github which will always fail.
Ideally, it can check for the presence of files in ELECTRON_BUILDER_BINARIES_CUSTOM_DIR, before attempting to download if there aren'tt any.
The enhancement could perhaps be somewhat aligned to these two related issues: Prevent duplicate downloads of electron binary #7079 feat: electron builder binaries base url from env #19
What do you think, @mmaietta?
I've also tried the Docker image, but the build process still attempts to download winCodeSign. If all dependencies (including winCodeSign, etc) could be packaged into the docker image, that would be very helpful and helps circumvent the above connectivity issues. Otherwise, teams will be totally blocked from using this great tool.
https://hub.docker.com/r/electronuserland/builder