6

Hi, I want to open Firefox from the terminal with SOCKS proxy setting enabled. I would like to define it in terminal while opening.

Can this be done? and obviously if it can does anyone know how?

Cant find info on this anywhere thanks

Meer Borg
  • 4,963
ufun2
  • 61
  • IS there any specific reason, that you'd open this from the terminal? – Frederik Spang Mar 18 '13 at 15:05
  • IS there any specific reason, that you'd want to know? i am building a small android app that would require this feature but have been stuck on this part im writing oon linux then migrate – ufun2 Mar 18 '13 at 15:35
  • 2
    Web browsers on Ubuntu all get their proxy settings from the network settings manager, so the proxy settings are independent of the individual browsers. You should check out this question for help on setting a proxy from the terminal http://askubuntu.com/questions/158557/setting-proxy-from-terminal –  Mar 18 '13 at 15:59

1 Answers1

4

Normally Web browsers such as Firefox take their proxy settings from the system through the http_proxy environment variable but this can be changed from the menu: "Edit" > "Preferences"

one

two

If from a terminal you enter firefox -ProfileManager you can create a separate profile for each of the proxies you want to use.

You can then open firefox with a specific profile with

firefox -P "profile1"

replacing profile1 with the profile for the proxy server you want.

That said the better way to do this is to use the http_proxy variable.

See here for more information on http_proxy

mh-cbon
  • 103
  • 5
Warren Hill
  • 22,112
  • 28
  • 68
  • 88
  • Unfortunately, Firefox (37.0.2) on Ubuntu 15.04 still fails to use the http_proxy variable (see https://bugzilla.mozilla.org/show_bug.cgi?id=224886) – user643722 May 12 '15 at 16:14