The requested URL returned error 502, corporate?

git 502 proxy error
the requested url returned error: 502 in git
github 502 error
the requested url returned error: 502 heroku
curl 22 the requested url returned error 502 internal error server connection terminated
git the requested url returned error: 407
the requested url returned error: 403
502 notresolvable git in eclipse

Does anyone know what the problem seems to be with git? I am getting this error when running running a git clone to clone from team foundation server (tfs).

 fatal: unable to access 'http://website.com/_git/project': The requested URL returned error: 502

This took me considerable amount of time to troubleshoot and fix this annoying issue.

In my case I had the http_proxy and https_proxy environment variables set on my PC. ( You can find them under control panel - System and Security - Advanced system settings - Env variables - System variables section bottom panel in windows 10)

Once I deleted those 2 environment variables ( highlight - delete - ok ) and closed the Git-Terminal window and re-opened it the problem (http 502) went away. Just to confirm I tested with Git GUI + VS Code + Git Term. Did git fetch/clone/push/etc ...

Note: I am in a corporate env behind a strict proxy but so is the Enterprise tfs URL therefore I do not need a proxy interfering between me and my tfs server. I suspect (cannot confirm or rule out) the proxy was playing a MITM. Client machine is Windows 10 latest build running git version 2.22.0.windows.1

The requested URL returned error 502, corporate?, This took me considerable amount of time to troubleshoot and fix this annoying issue. In my case I had the http_proxy and https_proxy  Total 4 (delta 3), reused 0 (delta 0) error: RPC failed; HTTP 502 curl 22 The requested URL returned error: 502 Bad Gateway fatal: The remote end hung up unexpectedly fatal: The remote end hung up unexpectedly Everything up-to-date user1@cloudshell:~/app-web-2 (in-210216)$.

For reference: Within a corporate environment behind an authenticating proxy server I had previously edited my git global config an override for the proxy server. Once I corrected this, I was able to connect.

Useful command:

git config --global --list


[filter "lfs"]
        clean = git-lfs clean -- %f
        smudge = git-lfs smudge -- %f
        process = git-lfs filter-process
        required = true
[user]
        name = GuyWicks
[user]
        email = guy.wicks@iworkhere.com
[http]
    proxy = http://public-cache:8080

[https]
    proxy = http://public-cache:8080

I commented out the four proxy lines (#)

Error 502 on git clone - Getting Help, git clone http://vcs.server.cu/user/repo.git. returns a 502 error: fatal: unable to access 'http://vcs.server.cu/user/repo.git/': The requested URL  A 502 is typically given by a proxy. Are you using a proxy? – Arnold Daniels Dec 17 '15 at 2:42

I was running into the same issue. For some reason I had http and Https proxies set up in my git config list. Removing those allowed me to clone successfully.

HTTP clone results in The requested URL returned error: 502 , fatal: unable to access 'https://servername/username/project.git/': The requested URL returned error: 502. env. is RHEL latest gitlab version. RPC failed; HTTP 502 curl 22 The requested URL returned error: 502 #1222. Closed ssbarnea opened this issue Nov 14, 2019 · 1 comment Closed RPC

The requested URL returned error: 502 · Issue #8041 · npm/npm , Hi, Throughout the day, I will randomly get 502 errors when doing an npm install. I am not sure if this is a problem with bitbucket or npm, I would  Hi, Throughout the day, I will randomly get 502 errors when doing an npm install. I am not sure if this is a problem with bitbucket or npm, I would like to find out for sure. I am using npm v2.8.3

Reinstalled Gitlab, getting Error 502 when pushing/pulling (#2851 , Error: I reinstalled Gitlab Omnibus on my Debian 8 server in oder to upgrade, the website works The requested URL returned error: 502. The requested URL returned error: 502. I have no issues to clone this repository from Windows 7 computer. And I am able to see the Git Stash server repository from web explorers on Windows 8.

error: RPC failed; HTTP 502 curl 22 The requested URL returned , Summary error: RPC failed; HTTP 502 curl 22 The requested URL returned error: 502 Bad Gateway fatal: The remote end hung up unexpectedly after upgrade  POST git-receive-pack (3231 bytes) error: RPC failed; HTTP 502 curl 22 The requested URL returned error: 502 Bad Gateway fatal: The remote end hung up unexpectedly fatal: The remote end hung up unexpectedly Everything up-to-date. I’d appreciate any help on this issue. Let me know if you need any additional information.

Comments
  • It is most likely an issue with the configuration of your proxy or the URL you are using. It's not something we can troubleshoot from here, because it's not an issue with a site we can access. Ask your supervisor to help you with the issue. We can't help you with an issue you have accessing a web page (unless that page is located at Stack Exchange somewhere, in which case you should be asking for help in Meta Stack Overflow or Meta Stack Exchange).
  • Any idea why the exact same url would work for my supervisor and not for me? We have tried to troubleshoot this issue for the past couple of hours now with no success :(
  • Yes. A difference in the proxy settings, a difference in the URL you're using, your gateway to the server, or a configuration issue on the server itself (not git) which (as I said previously) is nothing we can troubleshoot from here. The issue is with your route to that server, and we have no access to the information about your network or routing. If your supervisor can't help, get your IT department involved.
  • Okay thank you I will show them this post!
  • This solution worked for me. Thanks