How to set proxies for apt-cyg?

How to set proxies for apt-cyg, http and socks? I tried to use

export http_proxy= 

but it didn’t work.

+6
source share
5 answers

This should work:

 export ftp_proxy=http://[user]:[passwd]@[proxy.foo.com]:[portnumber] 
+8
source

I did this by setting two Windows environment variables: http_proxy and http_proxy. I used to have HTTP_PROXY, but this was not received.

Note that since Cygwin is a Windows process, after setting new environment variables, you need to start a new Cygwin process to get the changes.

+1
source

I'm not sure about Cygwin, but these are lines from my ~ / .bashrc

 export http_proxy=http://[user]:[passwd]@[proxy.foo.com]:[portnumber] export https_proxy=http://[user]:[passwd]@[proxy.foo.com]:[portnumber] export HTTP_PROXY=http://[user]:[passwd]@[proxy.foo.com]:[portnumber] export HTTPS_PROXY=http://[user]:[passwd]@[proxy.foo.com]:[portnumber] 

If cygwin is like bash, it should work.

0
source

You can also add everything to one line (it works well with cygwin / apt-get, built into mobaxterm - add it to .bashrc):

 export {ftp,http,https}_proxy=http://[user]:[passwd]@[proxy.foo.com]:[port] 
0
source

Old question, but none of the answers seem correct.

From what I can say, trying to make an unset proxy to run this in one of my mailboxes, I got this error: wget: could not resolve the host address' webproxystatic-mywork.com

It looks like apt-cyg is using wget. So this brings you to this question: setting up proxies in wget

The answer to this question is: set (or in my case unset) http_proxy / https_proxy in /etc/wgetrc :

 # 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://proxy.yoyodyne.com:18023/ #http_proxy = http://proxy.yoyodyne.com:18023/ #ftp_proxy = http://proxy.yoyodyne.com:18023/ # If you do not want to use proxy at all, set this to off. #use_proxy = on 
0
source

Source: https://habr.com/ru/post/899806/


All Articles