Merge pull request #33 from xylo/master

added support for https proxies
This commit is contained in:
Michael Bayne
2015-12-16 10:55:00 -08:00
2 changed files with 4 additions and 0 deletions
@@ -918,6 +918,8 @@ public class Application
if ((proxyHost = System.getProperty("http.proxyHost")) != null) {
args.add("-Dhttp.proxyHost=" + proxyHost);
args.add("-Dhttp.proxyPort=" + System.getProperty("http.proxyPort"));
args.add("-Dhttps.proxyHost=" + proxyHost);
args.add("-Dhttps.proxyPort=" + System.getProperty("http.proxyPort"));
}
// add the marker indicating the app is running in getdown
@@ -344,8 +344,10 @@ public abstract class Getdown extends Thread
{
if (!StringUtil.isBlank(host)) {
System.setProperty("http.proxyHost", host);
System.setProperty("https.proxyHost", host);
if (!StringUtil.isBlank(port)) {
System.setProperty("http.proxyPort", port);
System.setProperty("https.proxyPort", port);
}
log.info("Using proxy", "host", host, "port", port);
}