Aug 20, 2018

git: fatal: unable to access 'remote link': Received HTTP code 502 from proxy after CONNECT

Get a verbose log
export GIT_CURL_VERBOSE=1
git pull origin master
Confirm that the issue is related to proxy
Check your proxy


echo $http_proxy;echo $https_proxy;echo $HTTP_PROXY;echo $HTTPS_PROXY

Unset proxy

unset http_proxy;unset https_proxy;unset HTTP_PROXY;unset HTTPS_PROXY

Or

git config --add remote.origin.proxy ""


Now, the git command will work fine

To make it permanent, add the below to .bash_profile

export no_proxy=stash.company.com


Ref:

https://stackoverflow.com/questions/16538372/git-proxy-bypass



No comments:

Post a Comment