Sunday, 2 December 2012

Set proxy details for a Websphere (WAS) JVM


The three properties required are...
  • http.proxyHost
  • http.proxyPort
  • http.nonProxyHosts
These are specified as generic JVM arguments using the -D option as follows...
-Dhttp.proxyHost=stack1.com

This can be set either via the WAS admin console by navigating to...
Application servers > myServer > Process definition > Java Virtual Machine > genericJvmArguments

Or using wsadmin as follows...
AdminConfig.modify(jvm, [['genericJvmArguments', '-Dhttp.proxyHost=stack1.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts="localhost|stack1.com|127.0.0.1"']])

Where jvm is the reference to the relevant JavaVirtualMachine configID

No comments:

Post a Comment