Zero configuration proxy support

People expect build tools to just work, and requiring an extra configuration step (proxy) to have gradle work is inconvenient. Also when using a computer (laptop) in different network environments, changing settings is an extra hurdle. Finally when using PAC proxy scripts, the actual proxy being used depend on the URL, and such a setup can’t be used with a single/static proxy property.

There’s a java-level property ‘java.net.useSystemProxies’ that could be enabled (as a first step) by default, but it’s not yet perfect as it only supports manual proxy configuration (on windows at least) and not automatic/wpad ones.

Suggestion

Gradle/Gradlew could both include the proxy-vole library, configured with OS proxy detection. Although it could be turned off (e.g. as PAC script implies javascript execution, it may be worth performance-wise to replace it by a static config, if possible), that should IMO be the default behavior, so that the builds just works.

I’d be happy to contribute a PR (sounds pretty simple) should you support the idea.

Extra

Would fix GRADLE-2393

1 Like