How do I set the Java proxy settings in Ubuntu (10.04 or 12.04), from the command line? What I am aiming at is to get direct connection, but by default it takes it from browser settings which are meant to go via a proxy - just I don't want Java to go via the proxy.
I am running an application server in Ubuntu which serves remote desktop sessions. I can put the Java control panel into the user's desktop, and then they (each individual user) can set the proxy settings under Network Settings. However - this means I have to tell each user to make this setting, which is not workable.
I want it set via some command line or environment variable on the server itself, so it defaults to "direct connection". I am not familiar with Java programming and it won't help much to give me Java code for this, I think it must be possible to set the defaults upon Java startup? Any pointers are welcome.
How can I do this?
Instead of command line you can edit $javaDirectory/jre/lib/net.properties
.
Remove #
in-front of:
http.proxyHost="proxy host"
http.proxyPort="proxy port"
https.proxyHost="proxy host"
https.proxyPort="proxy port"
and set your proxy there.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With