x4h1d
x4h1d

Reputation: 6092

SSL issue on Homebrew installation

When I try to install Homebrew using terminal it fails with following error:

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1

Press RETURN to continue or any other key to abort
==> Downloading and installing Homebrew...
fatal: unable to access 'https://github.com/Homebrew/homebrew/': Could not resolve host: github.com
Failed during: git fetch origin master:refs/remotes/origin/master -n --depth=1

I assumed it is because of proxy setting. So I tried to reset git proxy using:

git config --global --unset http.proxy

and

git config --global --unset core.gitproxy

but failed again.

Please help.

Upvotes: 2

Views: 369

Answers (1)

Ortomala Lokni
Ortomala Lokni

Reputation: 62516

You have to set the proxy for git with

git config --global --add http.proxy proxyHost:proxyPort

but you have also to set the proxy for Homebrew itself with :

export ALL_PROXY=proxyHost:proxyPort

Upvotes: 1

Related Questions