9

In order to set proxy in Chromium browser, one needs to go to

Settings → Under the Hood → Change Proxy Settings → Network Proxy.

It's too complicated. How do I set http_proxy in shell? I've tried

export http_proxy=http://127.0.0.1:8080/

But it doesn't seem to work.

Also, if you only want to set the proxy on the Chromium browser -- not your entire network -- the command line is the only way to set the proxy just for the browser. How can one set the proxy on Chromium -- using the command line -- to solve this problem?

3
  • Why do you want to use command line?
    – raam86
    Sep 23, 2012 at 0:17
  • Do you only want to have the proxy for Chromium, or do you want one system-wide? That is, every application that connects to the Internet would be forced through this proxy.
    – Makoto
    Sep 23, 2012 at 0:30
  • 1
    I edited the question to demonstrate another problem. The Chromium GUI only changes the proxy for the entire network not just the browser. The command line allows one to override this. Thus, this question may be useful on Super User, if it can be migrated.
    – jmort253
    Sep 23, 2012 at 2:02

1 Answer 1

7

You have to use the --proxy-server argument.

From the Chromium Network Settings page:

--proxy-server=<scheme>=<uri>[:<port>];.. | <uri>[:<port>] | "direct://"
This tells Chrome to use a custom proxy configuration. You can specify a custom proxy configuration in three ways:

1) By providing a semi-colon-separated mapping of list scheme to url/port pairs.
For example, you can specify:
--proxy-server="http=foopy:80;ftp=foopy2"
to use HTTP proxy "foopy:80" for http URLs and HTTP proxy "foopy2:80" for ftp URLs.

2) By providing a single uri with optional port to use for all URLs.
For example:
--proxy-server="foopy:8080"
will use the proxy at foopy:8080 for all traffic.

3) By using the special "direct://" value.
--proxy-server="direct://"
will cause all connections to not use a proxy.


You can also have a look at this List of Chromium Command Line Switches.

1
  • 2
    beat me to it 54 seconds.
    – raam86
    Sep 23, 2012 at 0:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .