admin管理员组

文章数量:1620175

How to set Google Chrome’s proxy settings in command line on Linux? I am using Google Chrome on Linux and start it by google-chrome. How can I set the proxy using the command line? It tell me that my desktop is not supported but I can set the proxy in command line.

如何在Linux上的命令行中设置Google Chrome浏览器的代理设置? 我正在Linux上使用Google Chrome,并通过google-chrome 启动它。 如何使用命令行设置代理? 它告诉我不支持我的桌面,但是我可以在命令行中设置代理。

Use the --proxy-server option when starting the google-chrome.

启动google-chrome时使用--proxy-server选项。

For example, to set Chrome to use a Socks proxy localhost:8080, start Google Chrome with this command:

例如,要将Chrome设置为使用Socks代理localhost:8080,请使用以下命令启动Google Chrome:

$ google-chrome --proxy-server="socks://localhost:8080"

An individual proxy server is specified using the format:

使用以下格式指定单个代理服务器:

[<proxy-scheme>://]<proxy-host>[:<proxy-port>]

Where <proxy-scheme> is the protocol of the proxy server, and is one of:

其中<proxy-scheme>是代理服务器的协议,并且是以下之一:

"http", "socks", "socks4", "socks5".

If the <proxy-scheme> is omitted, it defaults to “http”. Also note that “socks” is equivalent to “socks5”.

如果省略<proxy-scheme> ,则默认为“ http”。 另请注意,“ socks”等效于“ socks5”。

Examples:

例子:

--proxy-server="foopy:99"

Use the HTTP proxy “foopy:99” to load all URLs.

使用HTTP代理“ foopy:99”加载所有URL。

--proxy-server="socks://foobar:1080"

Use the SOCKS v5 proxy “foobar:1080” to load all URLs.

使用SOCKS v5代理“ foobar:1080”来加载所有URL。

To check more options, on a host with Google Chrome installed:

要检查更多选项,请在装有Google Chrome的主机上:

$ man google-chrome
Answered by anonymous. 匿名回答。

翻译自: https://www.systutorials/how-to-set-google-chromes-proxy-settings-in-command-line-on-linux/

本文标签: 命令行浏览器如何在LinuxGoogle