-1

I cant seem to initialize the gcloud

heres the log

enter image description here

the mac is new. anyone has any ideas?

Itai Bar
  • 747
  • 5
  • 14
  • What does `gcloud info --run-diagnostics --verbosity=debug` show? – Chris Apr 27 '22 at 11:07
  • 2
    1) Do not use images. Copy and paste the text into your question. 2) You have a certificate problem. Try **brew install curl ca-certificates** which worked on older Macs. I am not sure about the correct command M1s. – John Hanley Apr 27 '22 at 18:32

1 Answers1

1

There could be many possible reasons like :

  • Networking configurations and any proxy that can cause the handshake to fail.
  • Antivirus, firewalls, or any other software that are preventing the traffic.
  • Corporate certificates are being used.
  • A real SSL issue (there could be a captive portal in between you and Google)
  • A Python version/system libraries with SSL issues (2.7.11 seems to work for most users, but you can try different minor versions, like 2.7.10 or 2.7.9)

In order to Authenticate whether this error has occurred due to proxy or not, you can try running below commands:

$ curl https://dl.google.com/ 

**Output**: <a href="https://www.google.com/chrome"> Found </a>

If you get a different output from the above mentioned one then, you're behind a proxy or portal.

Solutions :

  • Try running npm config set strict-ssl false This is an alternative shared in this url https://github.com/nodejs/node/issues/3742. I wouldn’t recommend this but it's a short and quick solution.
  • Also have a look at this thread on how the user added certificates manually to perform significantly better behind corporate proxy as opposed to the strict-ssl option. This solution is for Windows, but a user confirmed in the comment it is for OSX as well.
Priyashree Bhadra
  • 3,182
  • 6
  • 23