问题描述
我想从现有的计算引擎实例连接到数据存储,我得到:
数据存储API已启用,权限已设置,但GCE位于不同区域,一个项目 其他?
GCE ENV:
DATASTORE_DATASET = PROJECT_ID
DATASTORE_PRIVATE_KEY_FILE =绝对路径PEM文件
DATASTORE_SERVICE_ACCOUNT = SERVICE_ACCOUNT_EMAIL
任何提示,我应该怎么办/检查?我很困惑,因为我在本地环境中的配置完全相同 - 当我点击pyCharm中的play时,一切正常;)
也许我错过了一些东西.. 。
感谢您的帮助;)
目前Cloud Datastore客户端库中的。如果您在GCE运行,它会尝试使用的规则,然后在尝试其他验证方法之前失败。
I'm trying to connect to Datastore from existing compute engine instance and I'm getting:
the Datastore API is enabled, Permissions is set but GCE is in different zone, one project
what else ?
GCE env:
DATASTORE_DATASET = project_id
DATASTORE_PRIVATE_KEY_FILE = absolute path to pem file
DATASTORE_SERVICE_ACCOUNT = service_account_email
Any tips what should I do/check ? I'm confused because I have exactly the same configuration in my local environment - when I click "play" in pyCharm everything works well ;)
Maybe I missed something...
Thanks for your help ;)
This is currently a bug in the Cloud Datastore client library. If you are running on GCE, it will try to use the scope rules and then fail before trying other authentication methods.
这篇关于在python中从现有的Google计算引擎连接谷歌数据存储的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!