Solution 1: Update hosts file
Add bitbucket.org IP to /etc/hosts
file (It's work for me)
104.192.143.2 bitbucket.org
Solution 2: Config proxy server
Command to use:
git config --global http.proxy http://proxyuser:proxypwd@proxy.server.com:8080
- change
proxyuser
to your proxy user
- change
proxypwd
to your proxy password
- change
proxy.server.com
to the URL of your proxy server
- change
8080
to the proxy port configured on your proxy server
If you decide at any time to reset this proxy and work without proxy:
Command to use:
git config --global --unset http.proxy
Finally, to check the currently set proxy:
git config --global --get http.proxy
More details on Getting git to work with a proxy server