Search code examples
gitintellij-ideahttp-proxy

IntelliJ connection reset trying to git pull when connected to VPN


Everything works fine when I'm not connected to VPN. But when I connect to VPN and configure a proxy script on my system (Windows 10), IntelliJ is not able to do any remote git operations.

I have tried configuring the proxy script in IntelliJ Proxy settings, the "Check connection" part gives "Connection Successful" to the same git remote. Tried Invalidate/Restart as well.

I'm using IntelliJ Idea 2021.1.3

Thanks


Solution

  • Configuring the proxy with command-line git fixed the issue.

    "Check connection" just tries to connect to the given URL using the IntelliJ Proxy settings. However, all the git operations depend on the command-line git (whichever is configured in the settings).

    So I had to go through the proxy script (.pac file) and find the IP address and port from there and configure it using git config --global http.proxy command.

    Thanks @Ruslan Kuleshov for the tip