当前位置:网站首页>Setting up a proxy for the WGet command
Setting up a proxy for the WGet command
2020-11-09 11:37:00 【xxjbs001】
by wget Command settings agent
Experimental environment :ubuntu 12.04 LTS goagent
Method 1 、 Set the agent in the environment variable
export http_proxy=http://127.0.0.1:8087
Method 2 、 Use profile
by wget Using agents , Can be modified directly /etc/wgetrc, You can also create a new one in the home folder .wgetrc, And edit the content , This paper adopts the latter .
take /etc/wgetrc China and proxy Copy the relevant lines to ~/.wgetrc, And make the following changes :
#You can set the default proxies for Wget to use for http, https, and ftp.
# They will override the value in the environment.
https_proxy = http://127.0.0.1:8087/
http_proxy = http://127.0.0.1:8087/
ftp_proxy = http://127.0.0.1:8087/
# If you do not want to use proxy at all, set this to off.
use_proxy = on
here use_proxy = on Opened the agent , If you don't want to use a proxy , It's troublesome to modify this file every time , We can use -Y Parameters are set in the future :
-Y, --proxy=on/off Turn the agent on or off
Method 3 、 Use -e Parameters
wget There is no command line parameter set specifically for the agent itself , But there is one "-e" Parameters , You can specify on the command line that an original appears in ".wgetrc" Settings in . So you can specify a proxy on the command line in disguise :
-e, --execute=COMMAND perform `.wgetrc' Format order
for example :
wget -c -r -np -k -L -p -e "http_proxy=http://127.0.0.1:8087" http://www.subversion.org.cn/svnbook/1.4/
This is especially convenient for using a temporary proxy .
notes : If it is https, Then the parameter is :-e "https_proxy=http://127.0.0.1:8087"
Use https If you want to ignore the server-side certificate verification , have access to -k Parameters .
版权声明
本文为[xxjbs001]所创,转载请带上原文链接,感谢
边栏推荐
- Biden wins the US election! Python developers in Silicon Valley make fun of Ku Wang in this way
- 安卓开发——服务应用,计时器的实现(线程+服务)
- Method of creating flat panel simulator by Android studio
- Explain Python input() function: get user input string
- EFF 认为 RIAA 正在“滥用 DMCA”来关闭 YouTube-DL
- List of wechat video Number broadcasters October 2020
- Source code analysis of ThinkPHP framework execution process
- 安全(杂记)
- range_sensor_layer
- Analysis of the source code of ThinkPHP facade
猜你喜欢

手写Koa.js源码

How to query by page after 10 billion level data is divided into tables?

20201107第16课,使用Apache服务部署静态网站;使用Vsftpd服务传输文件

inet_pton()和inet_ntop()函数详解

Fedora 33 Workstation 的新功能

SQL语句实现水仙花数求取

Jsliang job series - 08 - handwritten promise

After SQL group query, get the first n records of each group

为wget命令设置代理

Capture bubbles? Is browser a fish?
随机推荐
EFF 认为 RIAA 正在“滥用 DMCA”来关闭 YouTube-DL
Handwriting Koa.js Source code
开源ERP招聘了
Commodity management system -- implementation of local preservation of new commodities
Aren't you curious about how the CPU performs tasks?
Analysis of the source code of ThinkPHP facade
Biden wins the US election! Python developers in Silicon Valley make fun of Ku Wang in this way
Android rights
From the practice, this paper discusses the problems caused by the inconsistent design of ruby syntax.
range_sensor_layer
一个简单的能力,决定你是否会学习!
典型分布式系统分析:Dynamo
ThinkPHP门面源码解析
安全(杂记)
“微服务”技术另一个可能更合适的名字
Understanding task and async await
Deng Junhui's notes on data structure and algorithm learning - Chapter 9
再读《重构》
在企业的降本增效诉求下,Cube如何助力科盾业务容器化“一步到位”?
2020.11.07面试总结(面试12k)