Skip to content

Latest commit

 

History

History
28 lines (20 loc) · 931 Bytes

File metadata and controls

28 lines (20 loc) · 931 Bytes

Proxy configuration

When operating behind a corporate proxy, you must take care of the proxy configuration of multiple tools.

Java

To ensure the JVM uses the proxy, you should specify the following options:

export JAVA_OPTS="-Djava.net.useSystemProxies=true"

Note: If your OS does not support the java.net.useSystemProxies property, or if the proxy is not properly configured in your OS, you can configure it manually with:

# Set your values here
host="your.proxy.com"
port="1234"

export JAVA_OPTS="-Dhttp.proxyHost=$host -Dhttp.proxyPort=$port -Dhttps.proxyHost=$host -Dhttps.proxyPort=$port"

If you are running an Oracle version of the JDK:

export JAVA_TOOL_OPTIONS=$JAVA_OPTS

Maven

The recommended method to specify corporate proxy information for Maven is to rely on the settings.xml file as documented here.