无法通过 Google sql 库创建 gcloud cloudsql 实例。 (无权提出此要求)
Can't create gcloud cloudsql instance through Google sql library. (not authorized to make this request)
我可以通过使用 Google 的 SDK 创建一个 cloudsql 实例,但我无法通过 Google 的 sqladmin 库创建它。
我不断收到
googleapiclient.errors.HttpError: <HttpError 403 when requesting https://www.googleapis.com/sql/v1beta4/projects/kentik-testing-175821/instances?alt=json returned "The client is not authorized to make this request.">
我已按照这些说明进行操作 https://cloud.google.com/compute/docs/tutorials/python-guide。
如有任何帮助,我们将不胜感激。整个周末都被困在这。
这是我相信的历史。很难说,因为我已经厌倦了很多事情。
625 gcloud auth application-default login
626 gcloud auth application-default login
627 unset GOOGLE_APPLICATION_CREDENTIALS
628 pip3 install --upgrade google-api-python-client
629 gcloud auth application-default login
630 env
631 env | grep GOOGLE
632 ls
633 kentik
634 cd intern-test-suite/
635 ls
636 chmod +x test.py
637 ./test.py
638 gcloud projects status
639 gcloud projects list
640 ./test.py kentik-testing-175821
641 ./test.py kentik-testing-175821 rsim-testing
642 cd
643 ls
644 which gcloud
645 gcloud auth login
646 gcloud auth application-default --help
647 history
我必须将 env GOOGLE_APPLICATION_CREDENTIALS = 设置为 SDK 创建凭据所在的位置。
export GOOGLE_APPLICATION_CREDENTIALS=/Users/<YOUR USER NAME>/.config/gcloud/application_default_credentials.json
我根据 documentation 你不需要这样做,但这似乎是我的解决办法。
我可以通过使用 Google 的 SDK 创建一个 cloudsql 实例,但我无法通过 Google 的 sqladmin 库创建它。
我不断收到
googleapiclient.errors.HttpError: <HttpError 403 when requesting https://www.googleapis.com/sql/v1beta4/projects/kentik-testing-175821/instances?alt=json returned "The client is not authorized to make this request.">
我已按照这些说明进行操作 https://cloud.google.com/compute/docs/tutorials/python-guide。
如有任何帮助,我们将不胜感激。整个周末都被困在这。
这是我相信的历史。很难说,因为我已经厌倦了很多事情。
625 gcloud auth application-default login
626 gcloud auth application-default login
627 unset GOOGLE_APPLICATION_CREDENTIALS
628 pip3 install --upgrade google-api-python-client
629 gcloud auth application-default login
630 env
631 env | grep GOOGLE
632 ls
633 kentik
634 cd intern-test-suite/
635 ls
636 chmod +x test.py
637 ./test.py
638 gcloud projects status
639 gcloud projects list
640 ./test.py kentik-testing-175821
641 ./test.py kentik-testing-175821 rsim-testing
642 cd
643 ls
644 which gcloud
645 gcloud auth login
646 gcloud auth application-default --help
647 history
我必须将 env GOOGLE_APPLICATION_CREDENTIALS = 设置为 SDK 创建凭据所在的位置。
export GOOGLE_APPLICATION_CREDENTIALS=/Users/<YOUR USER NAME>/.config/gcloud/application_default_credentials.json
我根据 documentation 你不需要这样做,但这似乎是我的解决办法。