gcloud 身份验证登录代理问题

问题描述 投票:0回答:2

当我尝试使用命令

gcloud auth login
向 GCloud 进行身份验证时,我收到以下错误消息:

Your browser has been opened to visit:

https://accounts.google.com/o/oauth2/auth?response_type=code&client_id=3...

ERROR: There was a problem with web authentication. Try running again with --no-browser.
ERROR: (gcloud.auth.login) Could not reach the login server. A potential cause of this could be because you are behind a proxy. Please set the environment variables HTTPS_PROXY and HTTP_PROXY to the address of the proxy in the format "protocol://address:port" (without quotes) and try again.

如何解决?

gcloud http-proxy
2个回答
1
投票

当我设置环境变量

$HTTP_PROXY
$HTTPS_PROXY
时,出现了这个问题。

解决方案只需取消设置变量即可:

  • unset HTTP_PROXY
  • unset HTTPS_PROXY

0
投票

我有同样的问题,但取消设置 HTTP_PROXY 和 HTTPS_PROXY 并没有解决它。还有其他解决办法吗?

© www.soinside.com 2019 - 2024. All rights reserved.