问题原文
原帖链接 · S. Pauk · CC BY-SA 4.0
Is it anyhow possible to run an ansible task from google.cloud plugin using a user account (not a service account)? We have already set up a comprehensive hierarchy of user groups and roles and translating that into service account will be a pain.
已采纳解答
原帖链接 · John Mahowald · CC BY-SA 4.0
No. Ansible google.cloud credentials must be service accounts.
Refer to the Ansible GCE Guide. auth_kind only changes how this service account is looked up:
serviceaccountUse the account fromservice_account_fileorservice_account_contents. This one is possibly the easiest to use.machineaccountUse the service account associated with the GCP instance running Ansible.applicationUse application default credentials associated with the APIs provided by thescopesparameter.
Automation accounts should not be end user accounts. Removes the temptation to do something interactively as the automation user. API key style creds are strong, unlike garbage human passwords.
Creating an service account is easy. The hard part was validating the roles...
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
