简体   繁体   English

谷歌云访问令牌到期

[英]Google Cloud Access Token Expiry

I'm trying to connect to the MySQL database with the authentication type gcp_iam_auth.我正在尝试使用身份验证类型 gcp_iam_auth 连接到 MySQL 数据库。 This requires me to always get a token from GCP via this command gcloud auth print-access-token , but the problem is that this token expires after one hour.这要求我始终通过此命令gcloud auth print-access-token token 从 GCP 获取令牌,但问题是该令牌在一小时后过期。 So I entered the MySQL Administration and tried to copy the password from my user.所以我进入了 MySQL Administration 并试图从我的用户那里复制密码。 I received a forbidden message ( Attached screenshot ).我收到了一条禁止消息(附上截图)。 How can I get this password?我怎样才能得到这个密码? Am I connecting the right way?我连接的方式正确吗?

https://i.stack.imgur.com/ymScU.png https://i.stack.imgur.com/ymScU.png

You cannot retrieve the password.您无法找回密码。 The system does not know the plain text password either.系统也不知道明文密码。

The command gcloud auth print-access-token is intended for developers to use while writing and testing software and not for long-term use ie the token is valid for 3,600 seconds (with default organization settings).命令gcloud auth print-access-token旨在供开发人员在编写和测试软件时使用,而不是长期使用,即令牌的有效期为 3,600 秒(使用默认组织设置)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Firebase 云消息传递:app/invalid-credential - 无法获取有效的 Google OAuth2 访问令牌 - Firebase Cloud messaging : app/invalid-credential - failed to fetch a valid Google OAuth2 access token 云功能 | 登录 Firebase 并返回访问令牌 - Cloud Functions | Login into Firebase and return access token 限制对 Google Cloud Function 的访问 - Restrict access to Google Cloud Function firebase 云存储限制读取访问令牌 - firebase cloud storage restrict read of access token 拉插件“com.google.cloud.artifactregistry.gradle-plugin”失败,因为“无法从 gcloud 或应用程序默认凭据获取访问令牌” - Pull plugin "com.google.cloud.artifactregistry.gradle-plugin" fail because "Failed to get access token from gcloud or Application Default Credentials" 无法访问 Google Cloud 实例 - Can not access Google Cloud Instance Google Cloud Build 获取身份令牌 - Google Cloud Build fetch Identity token 无法访问谷歌云计算引擎上的 Jenkins - Unable to access Jenkins on compute engine on google cloud Google Cloud Load Balancer Cloud Run 开发人员访问权限 - Google Cloud Load Balancer Cloud Run Developer Access id Token vs access_token google login web 中的 api - id Token vs access_token google login api in web
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM