I set the proxy server in 'global settings' for my tortoisehg in Windows. When I try to connect to bitbucket repositories, the generated command line by tortoisehg was hg clone --debug-- http://bitbucket.org/<path to repo>
.
The console shows as follows:
using http://bitbucket.org/<path to repo>
proxying through http://172.19.6.47:8080
http auth: user <username>, password not set
sending capabilities command
I also run wireshark to monitor the traffic. To my surprise the traffic is transferred to bitbucket directly. I thought it should send the packets to the proxy server first. Does it mean that my proxy server does not take effect? What can I do to make it take effect?
Select the Start button, then select Settings > Network & Internet > VPN. Select the VPN connection, then select Advanced options. Under VPN proxy settings, select the type of proxy setup you want to use, then enter the proxy server information for that VPN connection.
Your mercurial.ini
file should have a section like so:
[http_proxy]
host = aproxy.somedomain.com:1234
Check that it is present. Maybe it wasn't saved correctly?
I made a fake entry as above and tried a pull and immediately got a failure to connect to proxy.
The following two webpage have a right answer.
(1) http://d.hatena.ne.jp/falkenhagen/20091007/1254909363
(2) http://www.jameswampler.com/2010/06/10/configure-mercurial-hg-to-use-a-proxy-server/
From the second link, he says:
My laptop is behind our corporate firewall for most of the day, so being able to do an hg push/pull against bitbucket.org fails because it isn’t hitting or proxy server. To setup Mercurial to use a proxy server, edit your hrgc file in the .hg folder of your repository and add this section:
[http_proxy]
host = foo.bar:8000
passwd = password
user = username
Just change the values to your proxy server hostname and port, username and password.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With